chaco link zooming multiple plots of for one axis

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

chaco link zooming multiple plots of for one axis

Fabio Pliger
Hi,

Is it possible to link only the x-axis of 2 ( or more ) plots so when i zoom on the first plot, only the x-axis of the second plot is update and the y remains at the same state. I know it's possible to pass the range2d paremeter of the first plot when building up the second plot, but this links both axis. Specifically i'd like to use it to show events and analogic values on the same screen. For instance i can show the amient temperature, pression and umidity measured and the second plot shows the weather info ( 0 for cloudy and 1 for sunny )... The second plot shows binary data and there's no sense to zoom over the y axis.

thanks

FP

_______________________________________________
Enthought-Dev mailing list
[hidden email]
https://mail.enthought.com/mailman/listinfo/enthought-dev
Reply | Threaded
Open this post in threaded view
|

Re: chaco link zooming multiple plots of for one axis

bryce hendrix-2
On 04/12/2010 11:27 AM, Fabio Pliger wrote:

> Hi,
>
> Is it possible to link only the x-axis of 2 ( or more ) plots so when
> i zoom on the first plot, only the x-axis of the second plot is update
> and the y remains at the same state. I know it's possible to pass the
> range2d paremeter of the first plot when building up the second plot,
> but this links both axis. Specifically i'd like to use it to show
> events and analogic values on the same screen. For instance i can show
> the amient temperature, pression and umidity measured and the second
> plot shows the weather info ( 0 for cloudy and 1 for sunny )... The
> second plot shows binary data and there's no sense to zoom over the y
> axis.

You can set the index_range or value_range of the plots separately after
construction:

plot_a.index_range= plot_b.index_range

Now zooming on plot_b will update just the index_range (usually the x
axis) of plot_a.

Bryce
_______________________________________________
Enthought-Dev mailing list
[hidden email]
https://mail.enthought.com/mailman/listinfo/enthought-dev