Multivariate Pattern Analysis in Python

### Navigation

- index
- modules |
- modules |
- PyMVPA Home |
- Sitemap »

# mvpa2.mappers.fx.FxMapper

class `mvpa2.mappers.fx.``FxMapper`(axis, fx, fxargs=None, uattrs=None, attrfx='merge')

  Apply a custom transformation to (groups of) samples or features.

  Notes

  Available conditional attributes:

  - `calling_time+`: Time (in seconds) it took to call the node
  - `raw_results`: Computed results before invoking postproc. Stored only if postproc is not None.
  - `training_time+`: Time (in seconds) it took to train the learner

  (Conditional attributes enabled by default suffixed with `+`)

  Methods

  `forward`(data) | Map data from input to output space.
  `forward1`(data) | Wrapper method to map single samples.
  `generate`(ds) | Yield processing results.
  `get_postproc`() | Returns the post-processing node or None.
  `get_space`() | Query the processing space name of this node.
  `reset`() |
  `reverse`(data) | Reverse-map data from output back into input space.
  `reverse1`(data) | Wrapper method to map single samples.
  `set_postproc`(node) | Assigns a post-processing node Set to `None` to disable postprocessing.
  `set_space`(name) | Set the processing space name of this node.
  `train`(ds) | The default implementation calls `_pretrain()`, `_train()`, and finally `_posttrain()`.
  `untrain`() | Reverts changes in the state of this node caused by previous training

  Parameters:

  axis : {‘samples’, ‘features’}

  fx : callable

  fxargs : tuple

  uattrs : list

  > List of attribute names to consider. All possible combinations of unique elements of these attributes are used to determine the sample groups to operate on.

  attrfx : callable

  > Functor that is called with each sample attribute elements matching the respective samples group. By default the unique value is determined. If the content of the attribute is not uniform for a samples group a unique string representation is created. If `None`, attributes are not altered.

  enable_ca : None or list of str

  > Names of the conditional attributes which should be enabled in addition to the default ones

  disable_ca : None or list of str

  > Names of the conditional attributes which should be disabled

  Methods

  `forward`(data) | Map data from input to output space.
  `forward1`(data) | Wrapper method to map single samples.
  `generate`(ds) | Yield processing results.
  `get_postproc`() | Returns the post-processing node or None.
  `get_space`() | Query the processing space name of this node.
  `reset`() |
  `reverse`(data) | Reverse-map data from output back into input space.
  `reverse1`(data) | Wrapper method to map single samples.
  `set_postproc`(node) | Assigns a post-processing node Set to `None` to disable postprocessing.
  `set_space`(name) | Set the processing space name of this node.
  `train`(ds) | The default implementation calls `_pretrain()`, `_train()`, and finally `_posttrain()`.
  `untrain`() | Reverts changes in the state of this node caused by previous training

  `attrfx`
  `axis`
  `fx`
  `fxargs`
  `is_trained` = True

    Indicate that this mapper is always trained.

  `uattrs`

### Navigation

- index
- modules |
- modules |
- PyMVPA Home |
- Sitemap »