[Numpy-discussion] how to use masked arrays

Eric Firing efiring at hawaii.edu
Wed May 14 13:19:55 EDT 2008


Pierre GM wrote:
[...]
> 
> * If you want to access the underlying data directly, these two commands are 
> (almost) equivalent [1]:
>>>> mydata._data
>>>> mydata.view(np.ndarray)

Shouldn't the former be discouraged, on the grounds that a leading 
underscore, by Python convention, indicates an attribute that is not 
part of the public API, but is instead part of the potentially 
changeable implementation?

Eric



More information about the NumPy-Discussion mailing list