## matplotlib-users

 [Matplotlib-users] link axis subplots From: Miriam Gerrits - 2006-10-04 08:18:51 ```

Hi,

Is it possible in python/matplotlib to link the x-axis in the subplots. So if you zoom in in one of the graphs of the subplot, that then the other subplots also zoom in. In Matlab this function is called 'linkaxis'.

Miriam

```
 Re: [Matplotlib-users] link axis subplots From: John Hunter - 2006-10-06 15:20:23 ```>>>>> "Miriam" == Miriam Gerrits writes: Miriam> Hi, Miriam> Is it possible in python/matplotlib to link the x-axis Miriam> in the subplots. So if you zoom in in one of the graphs of Miriam> the subplot, that then the other subplots also zoom in. In Miriam> Matlab this function is called 'linkaxis'. ax1 = subplot(211) ax1.plot(rand(20)) ax2 = subplot(212, sharex=ax1) ax2.plot(rand(20)) JDH ```
 Re: [Matplotlib-users] link axis subplots From: Samuel GARCIA - 2006-10-06 15:26:03 Attachments: Message as HTML ```By the way, does anyone look into the possibility of changing the feature after drawing ? I already ask this question a few time ago but it still in suspend. thank you sam John Hunter wrote: >>>>>> "Miriam" =3D=3D Miriam Gerrits writes: >>>>>> =20 > > Miriam> Hi, > > Miriam> Is it possible in python/matplotlib to link the x-axis > Miriam> in the subplots. So if you zoom in in one of the graphs of > Miriam> the subplot, that then the other subplots also zoom in. In > Miriam> Matlab this function is called 'linkaxis'. > > > ax1 =3D subplot(211) > ax1.plot(rand(20)) > > ax2 =3D subplot(212, sharex=3Dax1) > ax2.plot(rand(20)) > > JDH > > -----------------------------------------------------------------------= -- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share= your > opinions on IT & business topics through brief surveys -- and earn cash > http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDEV > _______________________________________________ > Matplotlib-users mailing list > Matplotlib-users@... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > =20 --=20 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Samuel Garcia Universite Claude Bernard LYON 1 CNRS - UMR5020, Laboratoire des Neurosciences et Systemes Sensoriels 50, avenue Tony Garnier 69366 LYON Cedex 07 FRANCE T=E9l : 04 37 28 74 64 Fax : 04 37 28 76 01 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ```