I have two plots. first one is velocity data from servo controller (freq) - plant reciprocates back and forth so we got turn data in there as well second one is psd (power spectral density) so we can see where we got resonances etc.
When we zoom in on on section of first plot (say the forward movement), I'd like to recalc the psd with only the data that's been zoomed in on. Everything kind of works except for somewhere to trigger from. I had thought of trying resize_event - however I cannot get this working- see other post. I played with button_release_event to get the code basically working, however that event occurs before the first graph gets resized, so the region I am calculating the psd on is wrong, maybe because I am using xlim = myAxis.get_xlim() to find the limits of the first graph (which hasn't been re-drawn yet) Is there some way I can hook the re-calc/draw of psd to the zooming of first graph? Previously with 2 plot commands, I have used subplot(212, sharex=p1), to hook the two graphs together on the xaxis however as the second graph is a psd I don't know how to hook the psd input data to the xaxis of the first graph. Thanks Steve ------------------------------------------------------------------------- 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=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users