comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » the precision of PRINT and HELP statements
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
the precision of PRINT and HELP statements [message #26930] Thu, 04 October 2001 09:46 Go to previous message
george.mccabe is currently offline  george.mccabe
Messages: 10
Registered: October 2001
Junior Member
hello,

this one made me laugh when i realized what was going on -

IDL> help, chkN
CHKN LONG = 140486
IDL> help, float(Nhb)/Nreq0
<Expression> FLOAT = 140486.
IDL> print, chkN - float(Nhb)/Nreq0
-0.500000


perhaps one should expect IDL's PRINT statement to act this way,

IDL> print, float(Nhb)/Nreq0
140486.
IDL> print, format='(g)', float(Nhb)/Nreq0
140486.5

but, the HELP command i feel should show the actual value to the
precision of the variable type.

is there a way to set the format of HELP output, or adjust system wide
format settings?

thank you,
george, george.mccabe@gsfc.nasa.gov
[Message index]
 
Read Message
Read Message
Previous Topic: Polygon filling oddities
Next Topic: Using MIN on arrays : Exorcising loops?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 15:53:34 PDT 2025

Total time taken to generate the page: 0.00449 seconds