how to create custom marker

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

how to create custom marker

Octave - General mailing list
Hello,

When a marker is used in a plot, the marker does not change its size (size compared to screen). Two questions:

1) is it possible to create a custom marker to be used in a plot? If yes, how?

2) let's say that I have a 2D-filled region, but if I zoom in/out, the region will be zoomed too. How could I keep the size of the region fixed compared to screen (like a maker that does not change its size)?

Thanks


Reply | Threaded
Open this post in threaded view
|

Re: how to create custom marker

BGreen

On Thu, Apr 16, 2020 at 8:42 AM Leonardo via Help-octave <[hidden email]> wrote:
Hello,

When a marker is used in a plot, the marker does not change its size (size compared to screen). Two questions:

1) is it possible to create a custom marker to be used in a plot? If yes, how?

2) let's say that I have a 2D-filled region, but if I zoom in/out, the region will be zoomed too. How could I keep the size of the region fixed compared to screen (like a maker that does not change its size)?

Thanks


Marker properties are adjusted through line properties, which can be set for example through plot:

h = plot(rand(3),"marker","o","markersize",20,"color","blue")

You can always adjust the size of the marker later by using the plot handle

set(h,"markersize",40)

To scale it as you desire, just multiply the previous marker size by the factor by which you've zoomed in.