> I was also a bit surprised at the following behavior: >>> a = numpy.asarray([1,1]) >>> a array([1, 1]) >>> a[0]=numpy.nan >>> a array([0, 1]) Seems to affect only the int_ arrays: >>> a = numpy.asarray([1,1], dtype=float_) >>> a array([1., 1.]) >>> a[0]=numpy.nan >>> a array([ nan, 1. ])