我想从屏蔽数组中删除列,其中列中的每个值都被屏蔽。所以在下面的例子中:
>>> import numpy as np
>>> test = np.array([[1,0,0],[0,3,0],[1,4,0]])
>>> test = np.ma.masked_equal(test,0)
>>> test
[[1 -- --]
[-- 3  --]
[1  4  --]],
>>> np.somefunction(test)
[[1  --]
 [-- 3 ]
 [1  4 ]]
np.somefunction() 应该是什么来获得给定的输出?