On Mon, 2005-04-18 at 10:39 +0200, Edurne Dehesa wrote:
> Gnuplot.plot 'fichero0' with linespoints, 'fichero1' with linespoints
> ^
> SyntaxError: invalid syntax
Have a look at the examples, the plot object is not just a
prefix to the usual command line, but you can use it somewhat
that way. For example
pobj = Gnuplot.Gnuplot()
pobj( 'plot "file" with points, "fileb" with lines' )
or, from one of my scripts
pobj = Gnuplot.Gnuplot()
pobj.xlabel( xlab )
pobj.ylabel( ylab )
pobj( 'set zlabel "' + zlab + '"' )
pobj( 'set view 70,340,1.10' )
pobj( 'set grid xtics ytics' )
pobj( 'set contour' )
pobj( 'set cntrparam levels 10' )
pobj( 'set terminal png small transparent' )
pobj( 'set output "' + fileName + '"' )
dobj1 = Gnuplot.GridData( d1, x, y,
Gnuplot.PlotItems._unset,
title=d1Title,
with="lines" ),
pobj.splot( dobj1 )
pobj.reset()
> I would be also pleased if you could help me with another question: can I
> change names to every point in the axis??
Maybe you could construct a list of the points then use the more
complex form of "set xtics". See 'help set xtics' in Gnuplot.
If your dates are in seconds, I'm not sure. See the help for
xdata and timefmt, it should be possible.
Good luck
-- Simon
--
Simon Clift ssclift at math dot uwaterloo dot ca
Ph.D. Student, Computational Finance
Scientific Computing Group, School of Computer Science
University of Waterloo
Waterloo, Ontario, Canada N2L 3G1
|