[Numpy-discussion] Problem with numpy.records module

Pierre Barbier de Reuille pierre.barbierdereuille@gmail....
Fri Mar 22 05:41:13 CDT 2013


Hello,

I am trying to use titles for record arrays. In the documentation, it is
specified that any column can set to "None". However, using 'None' fails on
numpy 1.6.2 because in np.core.records, on line 195, the "strip" method is
called on the title object.

First, I hope I understood the documentation correctly. If so, is it
possible to replace the line 195 with:

    self._titles = [n.strip() if n is not None else None for n in
titles[:self._nfields]]

so 'None' elements are handled properly?

Thanks,

-- 
Barbier de Reuille Pierre
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20130322/76b8d24e/attachment.html 


More information about the NumPy-Discussion mailing list