(snip discussion of open kimono) > On the other hand, to try and conceal these implementation > differences, seems to me to break my feeling for numpy arrays, and > make me feel I have an object that is rather magic, that I don't fully > understand, and for which clever stuff is going on, under the hood, > that I worry about but have to trust.
To weigh-in as someone less tipsy, I totally agree with this concern. In fact, in trying to understand the proposal myself--and I use numpy R NAs all the time--it was difficult to understand, and I don't think I have fully gotten it yet. That makes it seem like magic, and magic makes me seriously nervous ... specifically, that I won't get what I intended, which will lead to nearly-impossible-to-find bugs. > I think this is not the numpy way. I think I fully understand why > it's attractive, but I continue to think that it's a mistake, and one > that may take some time to become clear. It will become clear only > after a few years of trying to teach people, and noticing that when > they get to this stuff, they start switching off, and getting a bit > confused, and concluding it's all too hard for them. Agreed. For ultra simplicity, I'd be perfectly happy with a np.NA element (bitpattern?) that I could use to represent points that will forevermore be missing, as well as a masking capability that allows multiple masking values (not just true/false) such as: a.mask[3] = 0 # unmasked a.mask[3] = 1 # masked "type 1" (eg, missing?) a.mask[3] = 2 # masked "type 2" (eg, data from different source) a.mask[3] = 3 # masked "type 3" (eg, ignore in complete-case analysis) etc. Regardless of whether a mask is boolean or more, though, the simplicity of explaining masking separate from NA cases is, I think, a huge win. -best Gary The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine at http://www.partners.org/complianceline . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail. _______________________________________________ NumPy-Discussion mailing list [email protected] http://mail.scipy.org/mailman/listinfo/numpy-discussion
