[pymvpa] PyMVPA

Nick Oosterhof nikolaas.oosterhof at unitn.it
Mon Aug 18 09:37:38 UTC 2014

On Aug 18, 2014, at 2:42 AM, cfygj <cfygj at 126.com> wrote:

> In my script, I have set " ds = remove_invariant_features(ds)". I think this setting has replaced those [that have NaN value] voxels with zeros.

Those features are not invariant.

from mvpa2.suite import *
from numpy import NaN, Inf

In [7]: dsc
Dataset(array([[  1.,  nan,  inf],
       [  0.,  nan,  inf]]), sa=SampleAttributesCollection(items=[]), fa=FeatureAttributesCollection(items=[]), a=DatasetAttributesCollection(items=[]))

I've created a PR that introduces remove_nonfinite_features: https://github.com/PyMVPA/PyMVPA/pull/236. Note that it does not remove invariant features.

More information about the Pkg-ExpPsy-PyMVPA mailing list