March 15, 2012
7:06 p.m.
On Thu, Mar 15, 2012 at 12:56 PM, Gökhan Sever <gokhansever@gmail.com>wrote: If not so, how can I return a set of False values if my masking condition
is not met?
Self-answer: I can force the mask to be filled with False's, however unsure if this is a safe operation. I50 x = np.array([1, 1.1, 2, 1.1, 3]) I51 y = np.ma.masked_values(x, 1.5, shrink=0) I52 y O52 masked_array(data = [1.0 1.1 2.0 1.1 3.0], mask = False, fill_value = 1.5) I53 y.mask = np.zeros(len(x), dtype=np.bool)*True I54 y O54 masked_array(data = [1.0 1.1 2.0 1.1 3.0], mask = [False False False False False], fill_value = 1.5)