![](https://secure.gravatar.com/avatar/f5e2eed5819807cb22e9d04eb66ab290.jpg?s=120&d=mm&r=g)
Hi all, I'm trying to write a small application using chaco to check some of my simulation results. It's actually also a bit of an exercise to learn chaco. Currently what I have is something like this: class ContainerTest(HasTraits): plot = Instance(VPlotContainer) traits_view = View(Item('plot', editor=ComponentEditor(), show_label=False), width=800, height=800, resizable=True, title='spectrum') def __init__(self): super(ContainerTest, self).__init__() I,f,z = load_field('test.h5') plotdata = ArrayPlotData(spectrum=Is) imageplot = Plot(self.plotdata) im = imageplot.img_plot("spectrum", xbounds=t, ybounds=z, colormap=jet)[0] LI = LineInspector(component=self.imageplot, write_metadata=True, inspect_mode='indexed', axis='index_y') imageplot.overlays.append(LI) line = ArrayPlotData(field=I[0],frequency=f) lp = Plot(self.line) lineplot = lp.plot(("frequency","field"), type="line") container = VPlotContainer(imageplot,lp) self.plot = container I is a spectrum of a field depending on frequency f and propagation distance z. So on top i have an imageplot of the spectral evolution, while at the bottom I have just the spectrum at one point of the evolution. What I'm trying to do with the LineInspector is that I'd like to be able to move it up and down and choose which spectrum to display in the bottom plot. I've looked at some of the examples and I understand I need to at an event handler using on_trait_change, however I can't find which object gets written the metadata to. Another (slight) problem I found is that if I change the interpolation to bilinear I have a white gradient overlaying at the top and bottom of the image. Can anyone point me in the right direction? As I'm a bit stuck atm. Cheers Jochen
![](https://secure.gravatar.com/avatar/764323a14e554c97ab74177e0bce51d4.jpg?s=120&d=mm&r=g)
On Sat, May 16, 2009 at 20:02, Jochen Schroeder <cycomanic@gmail.com> wrote:
Hi all,
I'm trying to write a small application using chaco to check some of my simulation results. It's actually also a bit of an exercise to learn chaco. Currently what I have is something like this:
Chaco questions should be directed to chaco-users or enthought-dev: https://mail.enthought.com/mailman/listinfo/chaco-users https://mail.enthought.com/mailman/listinfo/enthought-dev -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco
![](https://secure.gravatar.com/avatar/f5e2eed5819807cb22e9d04eb66ab290.jpg?s=120&d=mm&r=g)
On 16/05/09 20:11, Robert Kern wrote:
On Sat, May 16, 2009 at 20:02, Jochen Schroeder <cycomanic@gmail.com> wrote:
Hi all,
I'm trying to write a small application using chaco to check some of my simulation results. It's actually also a bit of an exercise to learn chaco. Currently what I have is something like this:
Chaco questions should be directed to chaco-users or enthought-dev:
https://mail.enthought.com/mailman/listinfo/chaco-users https://mail.enthought.com/mailman/listinfo/enthought-dev
Ah, sorry somehow I missed the chaco mailing list Cheers Jochen
-- Robert Kern
"I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco _______________________________________________ SciPy-user mailing list SciPy-user@scipy.org http://mail.scipy.org/mailman/listinfo/scipy-user
participants (2)
-
Jochen Schroeder
-
Robert Kern