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

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

[Octave-bug-tracker] [bug #32980] for backend FLTK, real is used for axe


From: Rik
Subject: [Octave-bug-tracker] [bug #32980] for backend FLTK, real is used for axes. double should be used
Date: Fri, 22 Apr 2011 16:21:32 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.16) Gecko/20110323 Ubuntu/10.04 (lucid) Firefox/3.6.16

Follow-up Comment #9, bug #32980 (project octave):

My inclination is for option 2.  I subscribe to the philosophy that the user
has more information, and is more intelligent, than the program and can make a
better choice on how to resolve an error situation.  Thus, I think we can just
issue a warning and produce an unreadable mess.  The user may then choose to
scale their graph, perhaps choose the gnuplot toolkit, change the plot type to
semilogy, etc.  What we have right now isn't workable because one can reach an
error state, such as having one of the limits set to Inf, that is impossible
to escape.

Also, regarding your patch.  I think it would be acceptable, when the value is
below realmin, to round down to 0 rather than round up to realmin.

Finally, even though the for loop in the patch is over only a few items, I
hate to see them in Octave.  Here is a sample way to avoid the loops by using
indexing that you might consider or modify.


# Assuming the axis limits are in vector axlims = [xlims ylims zlims]
axlims(abs (axlims) < realmin) = 0;
axlims(axlims > realmax) = realmax;
axlims(axlims < -realmax) = -realmax;
bad_lims = axlims(1:2:end) >= axlims(2:2:end);
if (any (bad_lims))
  error (...);
endif



    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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