octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #53647] Order of plot commands xlabel, hold &


From: Rik
Subject: [Octave-bug-tracker] [bug #53647] Order of plot commands xlabel, hold & plot fcts
Date: Sat, 14 Apr 2018 09:07:46 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:55.0) Gecko/20100101 Firefox/55.0

Update of bug #53647 (project octave):

                Category:                Plotting => Plotting with OpenGL   
                Priority:              5 - Normal => 3 - Low                
              Item Group:                    None => Incorrect Result       
                  Status:                    None => Confirmed              
                 Summary: xlabel, hold & plot fcts => Order of plot commands
xlabel, hold & plot fcts

    _______________________________________________________

Follow-up Comment #1:

Yes it does.  Best practice for Octave is to first plot your data, and then
annotate the graph with labels, titles, etc.  If you reverse the order of the
code it works just fine.


figure;
fs=1e6;
plot([1:1000]/fs, [1:1000].^2); 
hold on;
xlabel('Time [s]');


As an added bonus, there is no need to use the 'hold on' command since xlabel
will not clear the figure window.  So the shorter, working code is


figure;
fs=1e6;
plot([1:1000]/fs, [1:1000].^2); 
xlabel('Time [s]');


Marking this as confirmed since it is reproducible, but lowering the priority
since there is a simple workaround.


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?53647>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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