TDataSeriesICA< Data > Class Template Reference
Perfusion Analysis

Templated representation of a ICA series analyis. More...

`#include <mia/core/ica_template.hh>`

Inheritance diagram for TDataSeriesICA< Data >:
[legend]

## Public Types

typedef CIndepCompAnalysis::IndexSet | IndexSet
typedef Data::Pointer | PData

## Public Member Functions

PData | get_delta_feature (const IndexSet &plus, const IndexSet &minus) const
PData | get_feature_image (size_t idx) const
Data | get_incomplete_mix (size_t idx, const IndexSet &skip) const
const Data & | get_mean_image () const
Data | get_mix (size_t idx) const
std::vector< float > | get_mixing_curve (unsigned idx) const
CSlopeColumns | get_mixing_curves () const
Data | get_partial_mix (size_t idx, const IndexSet &comps) const
void | normalize ()
void | normalize_Mix ()
| Normalizes the Mixing Matrix columns to have zero mean.
bool | run (size_t ncomponents, bool strip_mean, bool ica_normalize, std::vector< std::vector< float > > guess=std::vector< std::vector< float > >())
void | set_approach (CIndepCompAnalysis::EApproach approach)
void | set_max_iterations (int n)
void | set_mixing_series (size_t index, const std::vector< float > &series)
| TDataSeriesICA (const CIndepCompAnalysisFactory &icatool, const std::vector< Data > &initializer, bool strip_mean)
| ICA initialization.
| ~TDataSeriesICA ()

## Detailed Description

template<class Data>
class TDataSeriesICA< Data >

Templated representation of a ICA series analyis.

This class provides a generic implementation for the ICA analysis of data series.

Template Parameters

  Data

  some kind of data set ofwhich series are analyzed The class Data must somehow provide:
  - a typedef Pointer for a pointer like representation of itself or on of its base classes (preferable based on boost::shared_ptr)
  - a typedef dimsize_type for its the size seperated into dimensions
  - a method get_size() that returns dimsize_type
  - a method size() that returns the number of elements hold by itself
  - STL comaptible const and non-const iterators returned by functions named begin() and end()

Definition at line 61 of file ica_template.hh.

## Member Typedef Documentation

## IndexSet

template<class Data>

typedef CIndepCompAnalysis::IndexSet TDataSeriesICA< Data >::IndexSet

a set of indices used for addressing a subset of the independend componsts

Definition at line 66 of file ica_template.hh.

## PData

template<class Data>

typedef Data::Pointer TDataSeriesICA< Data >::PData

a (shared) pointer to itself

Definition at line 69 of file ica_template.hh.

## Constructor & Destructor Documentation

## TDataSeriesICA()

template<class Data>

TDataSeriesICA< Data >::TDataSeriesICA | ( | const CIndepCompAnalysisFactory & | icatool,
|  | const std::vector< Data > & | initializer,
|  | bool | strip_mean )

ICA initialization.

The contructor for an ICA

Parameters

  icatool | tool used for the ICA analysis
  initializer | data set containing all the time steps of input data
  strip_mean | strip the mean from the series before processing

## ~TDataSeriesICA()

template<class Data>

TDataSeriesICA< Data >::~TDataSeriesICA | ( |  | ) |

## Member Function Documentation

## get_delta_feature()

template<class Data>

PData TDataSeriesICA< Data >::get_delta_feature | ( | const IndexSet & | plus,
|  | const IndexSet & | minus ) const

Evaluate a mix as sum and difference of ICs

Parameters

  plus | add these ICs
  minus | subtract these ICs

Returns
  the combined signal

## get_feature_image()

template<class Data>

PData TDataSeriesICA< Data >::get_feature_image | ( | size_t | idx | ) | const

Returns
  the feature data relating to component idx

## get_incomplete_mix()

template<class Data>

Data TDataSeriesICA< Data >::get_incomplete_mix | ( | size_t | idx,
|  | const IndexSet & | skip ) const

Evaluate a partial mix of the ICs

Parameters

  idx | time indes
  skip | set of components to skip when mixing

Returns
  the mixed data

## get_mean_image()

template<class Data>

const Data & TDataSeriesICA< Data >::get_mean_image | ( |  | ) | const

Returns
  the mean of the input data

## get_mix()

template<class Data>

Data TDataSeriesICA< Data >::get_mix | ( | size_t | idx | ) | const

Returns
  the mixed signal at index idx

## get_mixing_curve()

template<class Data>

std::vector< float > TDataSeriesICA< Data >::get_mixing_curve | ( | unsigned | idx | ) | const

Obtain a specific mixing curve

Parameters

  idx | index of requested curve, throws invalid_argument if index is out of bounds

Returns
  a mixing curve

## get_mixing_curves()

template<class Data>

CSlopeColumns TDataSeriesICA< Data >::get_mixing_curves | ( |  | ) | const

Returns
  the mixing curves as vector of vectors

## get_partial_mix()

template<class Data>

Data TDataSeriesICA< Data >::get_partial_mix | ( | size_t | idx,
|  | const IndexSet & | comps ) const

Evaluate a partial mix of the ICs by using the given indes set

Parameters

  idx | time indes
  comps | set of components to use when mixing

Returns
  the mixed data

## normalize()

template<class Data>

void TDataSeriesICA< Data >::normalize | ( |  | ) |

Normalizes the ICs to the range of [-1,1] and correct the mixing matrix accordingly. This operation does not change the output of a mix.

## normalize_Mix()

template<class Data>

void TDataSeriesICA< Data >::normalize_Mix | ( |  | ) |

Normalizes the Mixing Matrix columns to have zero mean.

## run()

template<class Data>

bool TDataSeriesICA< Data >::run | ( | size_t | ncomponents,
|  | bool | strip_mean,
|  | bool | ica_normalize,
|  | std::vector< std::vector< float > > | guess = std::vector< std::vector< float > >() )

Runs the ICA

Parameters

  ncomponents | retained components
  strip_mean | strip the mean from the input
  ica_normalize | normalize the ICA after processing
  guess | provide an initial guess (leave empty, if not wanted)

## set_approach()

template<class Data>

void TDataSeriesICA< Data >::set_approach | ( | CIndepCompAnalysis::EApproach | approach | ) |

Set the ICA approach to either FICA_APPROACH_DEFL(default) or FICA_APPROACH_SYMM.

Parameters

  approach |

## set_max_iterations()

template<class Data>

void TDataSeriesICA< Data >::set_max_iterations | ( | int | n | ) |

sets the number of iterations in the ICA

Parameters

  n |

## set_mixing_series()

template<class Data>

void TDataSeriesICA< Data >::set_mixing_series | ( | size_t | index,
|  | const std::vector< float > & | series )

replace a mixing series by a new set

Parameters

  index | component number of the mixing curve to be replaced
  series | new mixing data

The documentation for this class was generated from the following file:

- ica_template.hh