Improved plotting of DOUBLE data [message #15857] |
Tue, 15 June 1999 00:00  |
Liam Gumley
Messages: 473 Registered: November 1994
|
Senior Member |
|
|
There was a discussion here recently about the limitations of PLOT
because it converts it's arguments to single precision. I just stumbled
across the following interesting routines at the PV-WAVE website, which
seem to work fine under IDL5:
ftp://ftp.boulder.vni.com/pub/unsupported/wave_user/release/ plot_dbl.pro
ftp://ftp.boulder.vni.com/pub/unsupported/wave_user/release/ oplot_dbl.pro
For example, to show the limitations of PLOT in IDL5:
x = dindgen(10)
y = x*0.0001d + 1000d
plot, x, y, /ynozero, ytickformat='(f10.4)'
oplot, x, y + 0.0001d
Now try PLOT_DBL (which normalizes the data):
plot_dbl, x, y, /ynozero, ytickformat='(f10.4)'
oplot_dbl, x, y + 0.0001d
It seems to work reasonably well in the few examples I've tried.
Cheers,
Liam.
--
Liam E. Gumley
Space Science and Engineering Center, UW-Madison
http://cimss.ssec.wisc.edu/~gumley
|
|
|
Re: Improved plotting of DOUBLE data [message #15912 is a reply to message #15857] |
Fri, 18 June 1999 00:00  |
luthi
Messages: 20 Registered: March 1999
|
Junior Member |
|
|
Liam
You are perfectly right that the plot_dbl works well together with the
oplot_dbl procedure. But this only solves the problem for oplot, but not for
contour, surface aso. Since there would be no difficulty implementig this in
the style of oplot_dbl, it would take me at least one day of tedious work and
I think that this is, why we pay licenses to VNI or RSI.
One thing I would like to point out again: These plotting behaviour has been
known since 1995 by the technical staff at VNI/RSI who provided the
workarounds you mentioned (see the procedure header!). Since then three major
versions of PV-Wave have been released but the bug remains unnoticed by most
users (including me, who always trusted the plots produced by PV-Wave). How
many scientific results were misinterpreted due to inaccuracies in the
plotting routines?
By the way I don't think that the limitation of the plotting routines stems
from the use of single precision floats alone, but also from some basic design
flaws of these plotting routines. These errors manifest themselves in the
sometimes weird behaviour of plotting on date/time axes.
I would really like to see some plot/oplot/contour procedures which always
work, and be it the workarounds of plot_dbl, oplot_dbl, surface_dbl (yet
inexistent) ...
Cheers
Martin
--
============================================================
Martin Luethi Tel. +41 1 632 40 92
Glaciology Section Fax. +41 1 632 11 92
VAW ETH Zuerich
CH-8092 Zuerich mail luthi@vaw.baum.ethz.ch
Switzerland
============================================================
|
|
|