From: <kai...@t-...> - 2003-05-16 05:24:55
|
Hi Fernando, Thanks for your message! I will download IPython and look at what you've done. Unfortunately, it might take a while as I'm really busy with work and an infant :-( I'm forwarding this message to the Gnuplot-py-users mailing list so that other users can see your ideas and comment on them. If you haven't already done so, I suggest you subscribe to this list. By the way, are your changes relative to version 1.6 or relative to some CVS version? CVS has lots of changes and new features that I haven't gotten around to releasing yet so you might want to have a look at it. Some quick comments regarding your specific ideas: > -plot(y) -> plot a NumPy array against its indices I guess this is a special case if y has only one dimension? Sounds good. > -plot(x,y) -> plot y vs x I find this special case confusing because each argument to plot() is usually a single PlotItem. Instead of this you can type plot(Data(x,y)), which isn't much more typing and is unambiguous. > -plot(y1,None,y2) -> plot y1,y2 vs their indices (None is a separator) This even more confusing special case wouldn't be necessary if not for the previous one. > -plot(y,filename='out.eps') -> make eps output reliably > (there's a tricky timing issue which requires > retrying the print command with a sleep()) Isn't this what hardcopy() does? What is the advantage of this call vs. hardcopy()? If hardcopy has the timing problem you mention, I would be very interested to hear more details. (By the way, hardcopy() has really been improved in CVS; you should check it out if you haven't already.) > - Added the 'index' keyword arg to File, similar to Gnuplot's > index option to select a dataset from a file with multiple > datasets in it. Sounds good. Please let me know what version of Gnuplot.py was your starting point so that I can download IPython and use diff to see your changes. Thanks again! Michael Fernando Perez wrote: > I've been a longtime user of your Gnuplot.py modules, so much so that > I've written a fair amount of stuff which wraps around them and > extends them to make everyday life easier. First, thanks a lot for > putting out such a useful tool. > > Some of the changes I've made are for example a rewrite of the plot > command to handle cases like > > -plot(y) -> plot a NumPy array against its indices > -plot(x,y) -> plot y vs x > -plot(y1,None,y2) -> plot y1,y2 vs their indices (None is a separator) > -plot(y,filename='out.eps') -> make eps output reliably (there's a > tricky timing issue which requires retrying the print command with a > sleep()) > > - Added the 'index' keyword arg to File, similar to Gnuplot's index > option to select a dataset from a file with multiple datasets in it. > > ... plus a bunch of other stuff I don't remember now. I made all of > these changes with the main objective of easing interactive use as > much as possible, so that the least amount of typing at the command > line would produce the most results. > > > I've been including all of this in IPython for a long time > (http://ipython.scipy.org), and I wrap it in such a way as to make its > use fairly transparent. But I think that most of this code should go > into the mainline of your project. This would ease my maintenance > burden :), plus it would benefit all users of Gnuplot.py who don't > necessarily use IPython. I could then leave a very thin layer in > IPython, mainly just for interactive use (though perhaps even that > should be a Gnuplot.py sub-module, something like Gnuplot.Interactive > or somesuch). > > Anyway, if you think you are interested in this, why don't you take a > look at IPython? If you download it, you'll immediately see the > Gnuplot-related files. You can then have a look and we can discuss if > you want to integrate the code, and what the best approach would be. > > [...] > > Best regards, > > Fernando Perez. -- Michael Haggerty mh...@al... |