You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(15) |
Sep
(21) |
Oct
(15) |
Nov
|
Dec
(3) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(7) |
Feb
(6) |
Mar
(2) |
Apr
(5) |
May
(6) |
Jun
(3) |
Jul
(4) |
Aug
(4) |
Sep
(3) |
Oct
(14) |
Nov
(16) |
Dec
(10) |
2004 |
Jan
(5) |
Feb
(10) |
Mar
(4) |
Apr
(8) |
May
(1) |
Jun
(5) |
Jul
(5) |
Aug
(4) |
Sep
(10) |
Oct
(3) |
Nov
(4) |
Dec
|
2005 |
Jan
(1) |
Feb
(4) |
Mar
|
Apr
(15) |
May
(12) |
Jun
(1) |
Jul
(4) |
Aug
(3) |
Sep
(6) |
Oct
(7) |
Nov
(21) |
Dec
(11) |
2006 |
Jan
(16) |
Feb
(12) |
Mar
(4) |
Apr
(6) |
May
(5) |
Jun
(9) |
Jul
|
Aug
(5) |
Sep
(1) |
Oct
(10) |
Nov
(4) |
Dec
(3) |
2007 |
Jan
(6) |
Feb
(4) |
Mar
(6) |
Apr
(11) |
May
(1) |
Jun
(21) |
Jul
|
Aug
(6) |
Sep
(2) |
Oct
(4) |
Nov
|
Dec
|
2008 |
Jan
(14) |
Feb
(1) |
Mar
(5) |
Apr
(22) |
May
(4) |
Jun
(1) |
Jul
(7) |
Aug
(5) |
Sep
(7) |
Oct
(3) |
Nov
|
Dec
(1) |
2009 |
Jan
(14) |
Feb
(1) |
Mar
(9) |
Apr
(5) |
May
(6) |
Jun
(7) |
Jul
(8) |
Aug
(3) |
Sep
|
Oct
|
Nov
(2) |
Dec
(4) |
2010 |
Jan
(2) |
Feb
|
Mar
(6) |
Apr
(6) |
May
(34) |
Jun
|
Jul
(8) |
Aug
(3) |
Sep
|
Oct
(5) |
Nov
(3) |
Dec
(1) |
2011 |
Jan
|
Feb
(4) |
Mar
(3) |
Apr
|
May
|
Jun
(5) |
Jul
(9) |
Aug
(5) |
Sep
(9) |
Oct
(3) |
Nov
(10) |
Dec
(1) |
2012 |
Jan
(1) |
Feb
(3) |
Mar
(2) |
Apr
|
May
(2) |
Jun
(1) |
Jul
(5) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(3) |
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
(3) |
Nov
(2) |
Dec
(9) |
2014 |
Jan
(1) |
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(3) |
Oct
|
Nov
|
Dec
|
2015 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(3) |
2016 |
Jan
|
Feb
(4) |
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2018 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
12
(2) |
13
(1) |
14
|
15
(1) |
16
(2) |
17
|
18
|
19
|
20
|
21
|
22
|
23
|
24
(1) |
25
(1) |
26
|
27
|
28
(1) |
29
(10) |
30
(3) |
|
|
|
From: Benny M. <ben...@gm...> - 2008-04-30 16:28:27
|
This is a gnuplot question, please, read gnuplot help if this is possible, in gnuplot, starti with help ytics You could ask help on gnuplot lists also, this list is for the gnuplot module in Python. Benny 2008/4/30 Veelion Chong <ve...@gm...>: > Hi, All > > I want to plot a chart of my data. I want the xtics with different colors. > for example, my x data is > -3, -2, -1, 0, 1, 2, 3, > I want the text data less than 0 appears red, 0 is green, and large than 0 > is blue, which seems like, > -3(r), -2(r), -1(r), 0(g), 1(b), 2(b), 3(b), > I tried to use > 'set ytics tc rgb "#FF0000" (%f %f %f)' % (-3, -2, -1) > 'set ytics tc rgb "#00FF00" (%f)' % (0) > 'set ytics tc rgb "#0000FF" (%f %f %f)' % ( 3, 2, 1) > but only the last one take effect, why? > > How can I make x or y axis with different colors number? > > Thanks, > veelion > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Gnuplot-py-users mailing list > Gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-py-users > > |
From: Veelion C. <ve...@gm...> - 2008-04-30 14:40:46
|
Hi, All I want to plot a chart of my data. I want the xtics with different colors. for example, my x data is -3, -2, -1, 0, 1, 2, 3, I want the text data less than 0 appears red, 0 is green, and large than 0 is blue, which seems like, -3(r), -2(r), -1(r), 0(g), 1(b), 2(b), 3(b), I tried to use 'set ytics tc rgb "#FF0000" (%f %f %f)' % (-3, -2, -1) 'set ytics tc rgb "#00FF00" (%f)' % (0) 'set ytics tc rgb "#0000FF" (%f %f %f)' % ( 3, 2, 1) but only the last one take effect, why? How can I make x or y axis with different colors number? Thanks, veelion |
From: Benny M. <ben...@gm...> - 2008-04-30 07:11:19
|
2008/4/29 Michael Haggerty <mh...@al...>: > Mark Alford wrote: > > On Mon, 28 Apr 2008, John K. Parejko wrote: > >> The version of Gnuplot.py in SVN replaces Numeric with numpy. It > hasn't been > >> turned into a release yet, but if you can download the latest > subversion > >> trunk (there should be information on how to do this from the > sourceforge > >> page), it should work just fine with numpy. > > > > What is stopping us from turning the SVN version in to a release? > > I tested it on Fedora and it works fine. > > Is there anything else that I and others can do to expedite the process? > > All that is missing is a volunteer who will follow through. > > If you want to be that person, let me know what your sourceforge > username is and I'll give you the necessary permissions. There's even a > document RELEASES.txt telling roughly what I had to do to make the last > release. I started a bit with it after a call from Michael, what stopped me doing a release was that I needed time to look at the parts of test.py that where giving errors. I wanted to find the time to resolve those first. Should you be interested in releasing SVN Mark, as Michael says go ahead and send him his details. Solving the errors occuring could always be done later. I use SVN version on a weekly basis without problems. Benny > > Michael > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Gnuplot-py-users mailing list > Gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-py-users > |
From: BBands <bb...@ya...> - 2008-04-29 21:02:53
|
Well, it took a lot of digging to figure this one out. I won't bore you with the details; the bottom line is that the gnuplot.py directory was misnamed. On Windows 2000 it was C:\Python25\Lib\site-packages\gnuplot instead of C:\Python25\Lib\site-packages\Gnuplot jab--who has a MUCH cleaner workstation now John Bollinger, CFA, CMT www.BollingerBands.com If you advance far enough, you arrive at the beginning. ____________________________________________________________________________________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ |
From: Michael H. <mh...@al...> - 2008-04-29 20:34:37
|
BBands wrote: > I am running the SVN version of Gnuplot.py, Python 2.5.2 and gnuplot 4.1. > > import Gnuplot fails > > import gnuplot succeeds > > Since test.py and demo.py emply the Gnuplot syntax this seems a bit odd. > > I must be missing something, but I am not sure what. Yes, the Python module is called "Gnuplot", not "gnuplot". My guess is that either you have some other unrelated gnuplot module installed, or you are on an OS with a case-insensitive filesystem and somehow the main directory got installed with a lowercase letter instead of uppercase. Michael |
From: BBands <bb...@ya...> - 2008-04-29 16:00:02
|
I am running the SVN version of Gnuplot.py, Python 2.5.2 and gnuplot 4.1. import Gnuplot fails import gnuplot succeeds Since test.py and demo.py emply the Gnuplot syntax this seems a bit odd. I must be missing something, but I am not sure what. jab John Bollinger, CFA, CMT www.BollingerBands.com If you advance far enough, you arrive at the beginning. ____________________________________________________________________________________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ |
From: Michael H. <mh...@al...> - 2008-04-29 15:48:14
|
Mark Alford wrote: > On Mon, 28 Apr 2008, John K. Parejko wrote: >> The version of Gnuplot.py in SVN replaces Numeric with numpy. It hasn't been >> turned into a release yet, but if you can download the latest subversion >> trunk (there should be information on how to do this from the sourceforge >> page), it should work just fine with numpy. > > What is stopping us from turning the SVN version in to a release? > I tested it on Fedora and it works fine. > Is there anything else that I and others can do to expedite the process? All that is missing is a volunteer who will follow through. If you want to be that person, let me know what your sourceforge username is and I'll give you the necessary permissions. There's even a document RELEASES.txt telling roughly what I had to do to make the last release. Michael |
From: Mark A. <al...@wu...> - 2008-04-29 15:01:58
|
On Mon, 28 Apr 2008, John K. Parejko wrote: > The version of Gnuplot.py in SVN replaces Numeric with numpy. It hasn't been > turned into a release yet, but if you can download the latest subversion > trunk (there should be information on how to do this from the sourceforge > page), it should work just fine with numpy. What is stopping us from turning the SVN version in to a release? I tested it on Fedora and it works fine. Is there anything else that I and others can do to expedite the process? |
From: Benny M. <ben...@gm...> - 2008-04-29 10:03:31
|
2008/4/29 Johan Ekh <ekh...@gm...>: > Thanks Benny, > I think I may have an old version of Gnuplot.py. When I use "with_" I get > an error and when I use "with" > I still get the same behavior as before. > > How do I download and install the most recent version? obtain the version in svn, then run : python setup.py install > > > /Johan > > 2008/4/29 Benny Malengier <ben...@gm...>: > > Please, have a look in test.py file in subversion. > > > > To plot this do: > > > > import Gnuplot > > > > > > x = linspace(0.0, 1.8, 18) > > > y = 3 - 2*x + 2*sin(4*x) > > > points2 = transpose(array([x,y])) > > > > --> no, not needed ! > > > > > > > > > > > g = Gnuplot.Gnuplot(persist=1) > > > d = Gnuplot.Data(points2, with='linespoints', title='points2') > > > > --> no, do: > > d = Gnuplot.Data(x, y, with_='linespoints', title='points2') > > > > Benny > > > > > |
From: Johan E. <ekh...@gm...> - 2008-04-29 09:49:30
|
Thanks Benny, I think I may have an old version of Gnuplot.py. When I use "with_" I get an error and when I use "with" I still get the same behavior as before. How do I download and install the most recent version? /Johan 2008/4/29 Benny Malengier <ben...@gm...>: > Please, have a look in test.py file in subversion. > > To plot this do: > > import Gnuplot > > > > x = linspace(0.0, 1.8, 18) > > y = 3 - 2*x + 2*sin(4*x) > > points2 = transpose(array([x,y])) > > --> no, not needed ! > > > > > > > g = Gnuplot.Gnuplot(persist=1) > > d = Gnuplot.Data(points2, with='linespoints', title='points2') > > --> no, do: > d = Gnuplot.Data(x, y, with_='linespoints', title='points2') > > Benny > > |
From: Benny M. <ben...@gm...> - 2008-04-29 09:23:34
|
Please, have a look in test.py file in subversion. To plot this do: import Gnuplot > > x = linspace(0.0, 1.8, 18) > y = 3 - 2*x + 2*sin(4*x) > points2 = transpose(array([x,y])) --> no, not needed ! > > > g = Gnuplot.Gnuplot(persist=1) > d = Gnuplot.Data(points2, with='linespoints', title='points2') --> no, do: d = Gnuplot.Data(x, y, with_='linespoints', title='points2') Benny |
From: Johan E. <ekh...@gm...> - 2008-04-29 08:50:09
|
Hi all, I'm trying to make my first plot using Gnuplot.py. I'm using scipy and numpy and I have issued the following commands in my script: import Gnuplot x = linspace(0.0, 1.8, 18) y = 3 - 2*x + 2*sin(4*x) points2 = transpose(array([x,y])) g = Gnuplot.Gnuplot(persist=1) d = Gnuplot.Data(points2, with='linespoints', title='points2') g.plot(d) However, the plot consists of only one point, even though the vectors x and y look as I expect. I also get the following message: In [3]: Warning: empty x range [0:0], adjusting to [-1:1] Warning: empty y range [3:3], adjusting to [2.97:3.03] gnuplot_x11: Some character sets not available Does anyone know what I'm doing wrong? Best regards, Johan |
From: John K. P. <par...@sp...> - 2008-04-29 02:34:52
|
> So the question is: what should I do? > gnuplot-py requires Numeric which requires python 2.4 > > Isn't there a way to make gnuplot-py working with the new "num-py" > module and so with python 2.5? The version of Gnuplot.py in SVN replaces Numeric with numpy. It hasn't been turned into a release yet, but if you can download the latest subversion trunk (there should be information on how to do this from the sourceforge page), it should work just fine with numpy. John |
From: mattia p. <ma...@cs...> - 2008-04-28 22:44:31
|
Hello, I am a windows user and I need to make 2D-3D graphs. I used python to manage the data so I thought to integrate python with gnuplot. Surfing on the internet, I found the popular module gnuplot-py. To install gnuplot-py, "Numeric" module is required. But the site I found was about "num-py" an upgrade of Numeric and I installed it. But gnuplot-py does require "Numeric". So I tried to download Numeric and install it, but Numeric does not install on Python 2.5 So the question is: what should I do? gnuplot-py requires Numeric which requires python 2.4 Isn't there a way to make gnuplot-py working with the new "num-py" module and so with python 2.5? Thank you. /MP |
From: Benny M. <ben...@gm...> - 2008-04-25 07:32:41
|
The plot is a built in function working on the Gnuplot.Data, eg: data[i] = Gnuplot.Data(self.grid_x, self.sol[i],with_='lines', title='Solution at t=%g' %(time)) where sol is a solution over a grid, then eg to plot a number of profiles: g.title('Concentration profiles') g.xlabel('x [1e-6 m]') g.ylabel('Conc [mol/mm^3]') g.plot(data[0]) for val in data[1:]: g.replot(val) So it does not work on polar, to do what you want, keep interacting with gnuplot commands, so: g('set terminal x11') > g('set output') > g('set polar') > g('unset border') > g('unset xtics') > g('unset ytics') > g('set size square') > g('set xrange[-2:2]') > g('set yrange[-2:2]') and not: g.plot(1.7) instead: g.('plot(1.7)') Benny > > |
From: Baphijmm <bap...@gm...> - 2008-04-24 22:10:18
|
Hello, I have just begun to use python at all, much less gnuplot.py; I have to say first that so far, this is a great tool and I'm very glad it's out there and available. Now, at the moment I'm having a problem getting the utility to plot a polar circle. Below is the code being used: g('set terminal x11') g('set output') g('set polar') g('unset border') g('unset xtics') g('unset ytics') g('set size square') g('set xrange[-2:2]') g('set yrange[-2:2]') g.plot(1.7) It seems perfectly fine until it gets to the actual g.plot() part, where it gives me this error: Traceback (most recent call last): File "./pytest", line 83, in <module> g.plot(1.7) File "/opt/csw/lib/python/site-packages/Gnuplot/_Gnuplot.py", line 273, in plot self._add_to_queue(items) File "/opt/csw/lib/python/site-packages/Gnuplot/_Gnuplot.py", line 243, in _add_to_queue self.itemlist.append(PlotItems.Data(item)) File "/opt/csw/lib/python/site-packages/Gnuplot/PlotItems.py", line 543, in Data utils.write_array(f, set) File "/opt/csw/lib/python/site-packages/Gnuplot/utils.py", line 95, in write_array assert set.shape[0] > 0 IndexError: tuple index out of range This exact same set of equivalent commands produces a circle of radius 1.7 in gnuplot. Am I doing something wrong with the python itself? The documentation is highly sparse, and doesn't mention polar coordinate systems at all; as such, I couldn't find the answer there. |
From: <bm...@ca...> - 2008-04-16 08:35:22
|
Quoting diljeet kaur <dil...@ya...>: > > > hi > im new to gnuplot...so new,that after indeterminant number of > attempts to install gnuplot.py., im still trying to do same > > i have downloaded gnuplot-py-1.7.tar & untarred it no, you should check out the svn version with the svn command, then install from the dir you checked the repository out. 1.7 is too old. > even gave python setup.py install in directory created by untarring ok > It seemingly installs gnuplot correctly it seems so > but i cannot use it from a python ide > it gives following traceback in the dir you have a test.py program, try that by runniing: python test.py also errors? > > import Gnuplot,Gnuplot.funcutils > File "/usr/local/lib/python2.5/site-packages/Gnuplot/--init--.py" , > line 165 , in <module> > from gp import Gnuplot0pts , GnuplotProcess, test_persist > File "/usr/local/lib/python2.5/site-packages/Gnuplot/gp.py", line 41, > in <module> > from gp_unix import Gnuplot0pts , GnuplotProcess, test_persist > File "/usr/local/lib/python2.5/site-packages/Gnuplot/gp_unix.py", > line 116, in <module> > from os import popen > File "/usr/local/lib/python2.5/site-packages/Gnuplot/os..py", line > 134, in <module> > from os.path import > (curdir,pardir,sep,pathsep,defpath,extsep,altsep.devnull) > ImportError:No module named path ?? I would supposse the os.path module can be imported on your setup. Trhy it. On my box: python Python 2.5.1 (r251:54863, Mar 7 2008, 03:19:34) [GCC 4.1.2 (Ubuntu 4.1.2-0ubuntu4)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from os.path import >>> (curdir,pardir,sep,pathsep,defpath,extsep,altsep,devnull) >>> so that statement works just fine here. > > Note:(I have manually copied this traceback ,so,pls ignore trivial errors) > > Also i don't get wgnuplot.exe in tar you wouldn't in linux no, that is a windows executable. > Also,where should Numeric be installed.,,in directory of gnuplot or > in of python I have it in python as a package. Also scipy. Benny > Kindly help > > > Unlimited freedom, unlimited storage. Get it now, on > http://help.yahoo.com/l/in/yahoo/mail/yahoomail/tools/tools-08.html/ ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. |
From: diljeet k. <dil...@ya...> - 2008-04-16 03:05:27
|
hi im new to gnuplot...so new,that after indeterminant number of attempts to install gnuplot.py., im still trying to do same i have downloaded gnuplot-py-1.7.tar & untarred it even gave python setup.py install in directory created by untarring It seemingly installs gnuplot correctly but i cannot use it from a python ide it gives following traceback import Gnuplot,Gnuplot.funcutils File "/usr/local/lib/python2.5/site-packages/Gnuplot/--init--.py" , line 165 , in <module> from gp import Gnuplot0pts , GnuplotProcess, test_persist File "/usr/local/lib/python2.5/site-packages/Gnuplot/gp.py", line 41, in <module> from gp_unix import Gnuplot0pts , GnuplotProcess, test_persist File "/usr/local/lib/python2.5/site-packages/Gnuplot/gp_unix.py", line 116, in <module> from os import popen File "/usr/local/lib/python2.5/site-packages/Gnuplot/os..py", line 134, in <module> from os.path import (curdir,pardir,sep,pathsep,defpath,extsep,altsep.devnull) ImportError:No module named path Note:(I have manually copied this traceback ,so,pls ignore trivial errors) Also i don't get wgnuplot.exe in tar Also,where should Numeric be installed.,,in directory of gnuplot or in of python Kindly help Unlimited freedom, unlimited storage. Get it now, on http://help.yahoo.com/l/in/yahoo/mail/yahoomail/tools/tools-08.html/ |
From: Benny M. <ben...@gm...> - 2008-04-15 06:57:16
|
2008/4/13, zhang chi <zha...@gm...>: > > hi > I have a 10X10 matrix in python, I want to draw a 3d graphic for this > matrix by using gnuplot.py. Zhang, gnuplot contains a test program with examples. Locate the gnuplot data, and open the test.py file. There you will find code to test the GridData way of using gnuplot. You find examples of what you want to do. For your reference, a copy here of that test: # set up x and y values at which the function will be tabulated: x = numpy.arange(35)/2.0 y = numpy.arange(30)/10.0 - 1.5 # Make a 2-d array containing a function of x and y. First create # xm and ym which contain the x and y values in a matrix form that # can be `broadcast' into a matrix of the appropriate shape: xm = x[:,numpy.newaxis] ym = y[numpy.newaxis,:] m = (numpy.sin(xm) + 0.1*xm) - ym**2 wait('a function of two variables from a GridData file') g('set parametric') g('set data style lines') g('set hidden') g('set contour base') g.xlabel('x') g.ylabel('y') g.splot(Gnuplot.GridData(m,x,y, binary=0, inline=0)) How to do this work? I try the following code ,but it did not work. > > #!/usr/bin/env python > > import Gnuplot, Gnuplot.funcutils > from numpy import * > import time > > g = Gnuplot.Gnuplot(debug=1) > > g.set(xrange=(0,10)) > g.set(xrange=(0,10)) > g.set(zrange=(0,10)) > z = ones((10,10)) > g.splot('z') > time.sleep(5) > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Gnuplot-py-users mailing list > Gnu...@li... > https://lists.sourceforge.net/lists/listinfo/gnuplot-py-users > > |
From: zhang c. <zha...@gm...> - 2008-04-13 02:03:27
|
hi I have a 10X10 matrix in python, I want to draw a 3d graphic for this matrix by using gnuplot.py. How to do this work? I try the following code ,but it did not work. #!/usr/bin/env python import Gnuplot, Gnuplot.funcutils from numpy import * import time g = Gnuplot.Gnuplot(debug=1) g.set(xrange=(0,10)) g.set(xrange=(0,10)) g.set(zrange=(0,10)) z = ones((10,10)) g.splot('z') time.sleep(5) |
From: novakyu <no...@gm...> - 2008-04-12 01:47:14
|
On Fri, Apr 11, 2008 at 6:21 PM, zhang chi <zha...@gm...> wrote: > g = Gnuplot.Gnuplot(debug=1) > g('set key left box') > g('set samples 50') > g.plot([[-10:10]],sin(x),atan(x),cos(atan(x))) > time.sleep(5) According to Gnuplot documentation (try "help(Gnuplot.Gnuplot.plot)"), the arguments to the plot() has to be either a PlotItem object or a string (or something that can be convertible to those). Changing the g.plot command to g.plot('sin(x)', 'atan(x)', 'cos(atan(x))') seems to work, and it seems rather silly to specify [-10:10], given that that's the default range, but if you need to, you can probably do it by issuing a command to set xrange to what you want. Regards, Andrzej P.S. I think py-gnuplot has many of the common functions and methods built-in---what you have here as raw gnuplot command probably can be written in terms of methods provided by py-gnuplot, although the end result is more or less the same. |
From: zhang c. <zha...@gm...> - 2008-04-12 01:21:23
|
hi I am a beginner to use py-gnuplot, here are gnupot commands, and I want to realize them in py-gnuplot, but my program can't run. gnuplot: set key left box set samples 50 plot [-10:10] sin(x),atan(x),cos(atan(x)) my program: #!/usr/bin/env python import Gnuplot, Gnuplot.funcutils from numpy import * import time g = Gnuplot.Gnuplot(debug=1) g('set key left box') g('set samples 50') g.plot([[-10:10]],sin(x),atan(x),cos(atan(x))) time.sleep(5) |