Dynamic graphs under gtk or other widget set

Jeremy Jones dnjjones at yahoo.com
Thu Aug 9 08:16:37 EDT 2001


Tom Huckstep <tom1 at redant.freeserve.co.uk> wrote in message
news:9kr12v$hs3$1 at s1.uklinux.net...

> I would like to write a mathematical function graph
> plotting program in python with the capability to draw
> `dynamic' graphs.  I'll explain what I mean by dynamic:

> In order to plot functions of two variables, one variable,
> x, say, will change as you move along the x-axis, but the
> other, a, say, will change with time.  A graph of
> f(x,a) = ax will be represented as a straight line that
> gets steeper with time.

Don't know if it will meet your needs or not, but gnuplot is a pretty good
all-purpose plotter.  It will plot mathematical functions as well as sets of
points stored in a file (comma or tab delimited, I don't remember which).  I
suppose that if you can create a mathematical function for it, gnuplot can
plot it.  Also, there is a python interface to it called gnuplot.py at
sourceforge:
http://gnuplot-py.sourceforge.net/
http://sourceforge.net/projects/gnuplot-py/
<note>I have never used gnuplot.py.  I have only used gnuplot and only with
sets of points (and only once with mathematical functions, just to get the
hang of the application).  But it seemed to work rather well for what I used
it for.</note>

> If possible I would like to do this with gtk, because I
> would like to modify a program I have found that already
> plots `static' graphs, but if this isn't possible I'd be
> happy to use any widget set.

Don't know if it (gnuplot.py or gnuplot) will work with gtk.  Gnuplot
primarily either pops up an X window with the result of the graph (if you
are on UNIX) or will store to a variety of different file types.  Hope this
helps.






More information about the Python-list mailing list