From: Leonardo M. <lm...@ud...> - 2004-09-30 15:23:16
|
On Thursday 30 September 2004 10:39, Dee Wortman wrote: > > Thanks Leo, > > That's what I think is happening as well, but as you know, with gnuplot no way to prove it. I guess it is time to experience the world of Python and gnuplot-py. > > Thanks again, > Dee My pleasure :-) IMHO if you need a jump start, you may wanna: 1) Install Python + Numeric extension 2) Install gnuplot-py 3) Run and play with the test/sample code in Gnuplot-py. 4) quick read to the python tutorial 5) http://docs.python.org/tut/tut.html 6) get familiar with the docs, http://www.python.org/doc/ I always end up browsing the modules index: http://docs.python.org/modindex.html You'll need at least http://docs.python.org/lib/module-os.html http://docs.python.org/lib/module-os.path.html One afternoon and plenty of coffee/green tea should do, really! Gotta go, best! -- leo > > > I was thinking about using gnuplot-py to try to take of a problem I am having with gnuplot itself. I have a gnuplot script that runs in a endless 6 second loop (on purpose) that reads a data file that is updated with new data every 4 seconds. Eventually though, it will abort with the following message: > > > > > > gnuplot> plot 'gnuplot.txt' index 0 using 1:2 with points 09, > > 'gnuplot.txt' index 1 using 1:2 with points 04, > > 'gnuplot.txt' index 2 using 1:2 with points 03, > > 'deviation_upper.txt' thru (( $1 * $2)/(-10.*55.1))**2 with lines 12, > > 'deviation_lower.txt' thru ((($1 * $2)/(-10. *55.1))**2)* -1 with lines 12 , > > U_CPS2 with lines 11 , L_CPS2 with lines 11 > > ^ > > "/emsdat/santee/scripts/gplot/cps.pl", line 25395: no data point found in specified file > > > > Attached is the script and I would appreciate any suggestions on how to make it work before I dive into Python. If anyone thinks gnuplot-py can fix the problem I would be most thankful for some help in getting started. > > maybe gnuplot, everyonce in a while, trys to read a data file while it > is being updated ? If the period of data update and data reading from > gnuplot are 6 and 4 seqs, chances are they'll meet at 12, 24, 36 sec. (assuming > they start at the same time) > > The advantage I would see on using gnuplot-py is that. within a python > script, you can check for existance/sanity of the data files before > feeding the gnuplot. So, you could, within the loop: > > start endless loop: > * import data files data into python arrays if files exist > * check that the data is actually there, check types, value ranges, etc. > * plot > * wait some time > > Hope this helps, > Leo > > > > ------------------------------------------------------- > This SF.net email is sponsored by: IT Product Guide on ITManagersJournal > Use IT products in your business? Tell us what you think of them. Give us > Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more > http://productguide.itmanagersjournal.com/guidepromo.tmpl > _______________________________________________ > Gnuplot-py-users mailing list > Gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-py-users > > > > > ____________________ > Confidentiality Notice: > This message is intended exclusively for the individual or entity to which it is addressed. This communication may contain information that is proprietary, privileged, confidential or otherwise legally exempt from disclosure. If you are not the named addressee, you are not authorized to read, print, retain, copy or disseminate this message or any part of it. If you have received this message in error, please notify the sender immediately either by phone or reply to this e-mail, and delete all copies of this message. |