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

Home » Public Forums » archive » how to prevent NaNs
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: how to prevent NaNs [message #91783 is a reply to message #91776] Wed, 26 August 2015 06:43 Go to previous message
Paul Van Delst[1] is currently offline  Paul Van Delst[1]
Messages: 1157
Registered: April 2002
Senior Member
On 08/25/15 10:03, g.nacarts@gmail.com wrote:
> Hi
>
> I had two FLOAT arrays that contains zeroes. Because I divide those
> two arrays I ended up with NaNs.
>
> Array = REFORM(A[1,*,*]/A[2,*,*])
>
> Does anyone knows how to prevents Nans and simply replace by zero?
> Where the A[1,*,*]/A[2,*,*] = 0./0. = 0 instead of NaN.
>
Check out the FINITE() function.

cheers,

paulv
[Message index]
 
Read Message
Read Message
Previous Topic: Mean = NaN if NaN present
Next Topic: Gradient idl

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

Current Time: Wed Oct 08 13:39:30 PDT 2025

Total time taken to generate the page: 0.00367 seconds