help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

problem with "hold" command


From: Rockwood, Alan
Subject: problem with "hold" command
Date: Mon, 17 Sep 2001 16:01:34 -0600

I am having a problem with the "hold" command in octave 2.1.31. I have an
m-file that  includes the following lines near the end of the program:

plot(TS,'.')
title(['Savitzky-Golay ' num2str(pit) ' points , degree = ' num2str(m)])
hold on
plot(TSP)
hold off

The problem is that "hold" doesn't work properly. The program is supposed to
overly a second plot over a first plot. However ends up erasing the first
plot and showing only the second plot. Interestingly, if I remove the "on"
and "off" parameters then the program works as expected, i.e. the "hold"
command toggles between the"on" and "off" states, and it overlays the plots.
Of course, this is not a good solution because the results depend on the
previous state of "hold".

What can I do to make "hold on" and "hold off" work?



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]