[Tutor] filtering NaN values

John Fouhy john at fouhy.net
Tue Jun 23 08:20:25 CEST 2009


2009/6/23 Alan Gauld <alan.gauld at btinternet.com>:
> Interesting! How is a NaN stored in Python?
> ie. How do you get to the point of having one in the first place?

Well, you can do this:

>>> float('nan')
nan

(try float('inf') too)

-- 
John.


More information about the Tutor mailing list