I have just installed plplot on my Linux PC.
I would need some help on the following points :
(I use Linux Mandrake 8.0 on an PC Athlon 700 MHz)
1/ Is there a function that
simply erases the rectangular box
and its content (the graph)
but not the legend for the x,y axis,
and the titel of the graph ?
I use plplot to plot a pressure distribution
at each iteration
and so far I have to erase everything,
and replot at each time step
a new box, legend, title and set a data using
at each iteration with
pllab("axial chord in %","-Cp","-Cp distribution round the airfoil");
plline(215, plplot_Cp_x, plplot_Cp_y);
2/ Is there a function like plline that
automatically detects the min and max
of the 2D dataset
and format xmin,xmax,ymin,ymax to their appropriate values ?
Like the function plot in gnuplot.
plsdev("xwin"); is OK
If now I change it into
just for a change and see what happens
because I have gnome installed by default,
my code crashes unexpectedly.
I do not report the error since my code
enters a routine though it should not, and
do not find the appropriate file (?).
Such a weird thing does not happen using xwin.
This error is no big deal for me.
I thank you for your help.
Alan W. Irwin
1) I am not aware of any such erase function. But the overhead for redrawing axes, title, etc. for a new page is small (assuming you are going to actually take time to look at the plot), and is probably less than what an erase would be. Also, look at the plbox documentation. There are options to not plot the title, etc., which should lower your overhead if you are worried about it.
2) I do my maximum and minimum calculations in the front ends. This is really easy for the yorick front-end (see the yplot package) or the python front end that I am familiar with.
3) The gnome driver is still in alpha state, and it will probably be at least a few months before that is actively developed again. If you want some variety you can try the tk driver, the ntk driver (if you download the CVS version), or the pyqt GUI (if you use python and also download the latest CVS). The drivers that you have to get from cvs are obviously pretty new so there may be some glitches, but they have worked pretty well for me recently
Regarding #1, as mentioned here the overhead in the axes & label draws is pretty low so it doesn't hurt to just regenerate them. If you don't like the "flicker" from frame to frame as everything gets redrawn, and you're using an X display, you might want to try the double buffer option (-db from the command line or use the plsetopt call).
You can always kludge an erase using a rectangular fill using the background color, but you're on your own there.