Tucker: Difference between revisions

From Eigenvector Research Documentation Wiki
Jump to navigation Jump to search
imported>Jeremy
(Importing text file)
 
imported>Jeremy
(Importing text file)
Line 7: Line 7:
===Description===
===Description===
TUCKER decomposes an array of order ''K'' (where ''K'' ? 3) into the summation over the outer product of ''K'' vectors. As opposed to PARAFAC every combination of factors in each mode are included (subspaces). Missing values must be NaN or Inf.
TUCKER decomposes an array of order ''K'' (where ''K'' ? 3) into the summation over the outer product of ''K'' vectors. As opposed to PARAFAC every combination of factors in each mode are included (subspaces). Missing values must be NaN or Inf.
INPUTS:
====INPUTS====
* x = the multi-way array to be decomposed and
* '''x''' = the multi-way array to be decomposed and
* ncomp = the number of components to estimate, or
* '''ncomp''' = the number of components to estimate, or
* model =  a TUCKER model structure.
* '''model''' =  a TUCKER model structure.
OPTIONAL INPUTS:
====OPTIONAL INPUTS====
* ''initval'' = if ''initval'' is the loadings from a previous TUCKER model are then these are used as the initial starting values to estimate a final model,  
* '''''initval''''' = if ''initval'' is the loadings from a previous TUCKER model are then these are used as the initial starting values to estimate a final model,  
*  if ''initval'' is a TUCKER model structure then mode 1 loadings (scores) are estimated from x and the loadings in the other modes (see output pred),
'''if''' ''initval'' is a TUCKER model structure then mode 1 loadings (scores) are estimated from x and the loadings in the other modes (see output pred),
*'' options'' =  discussed below.
*'''''''' options'' =  discussed below.
OUTPUTS:
====OUTPUTS====
* model = a structure array with the following fields:
* '''model''' = a structure array with the following fields:
* modeltype: 'TUCKER',
* '''modeltype''': 'TUCKER',
* datasource: structure array with information about input data,
* '''datasource''': structure array with information about input data,
* date: date of creation,
* '''date''': date of creation,
* time: time of creation,
* '''time''': time of creation,
* info: additional model information,
* '''info''': additional model information,
* loads: 1 by ''K''+1 cell array with model loadings for each mode/dimension,
* '''loads''': 1 by ''K''+1 cell array with model loadings for each mode/dimension,
* pred: cell array with model predictions for each input data block,
* '''pred''': cell array with model predictions for each input data block,
* tsqs: cell array with T<sup>2</sup> values for each mode,
* '''tsqs''': cell array with T<sup>2</sup> values for each mode,
* ssqresiduals: cell array with sum of squares residuals for each mode,
* '''ssqresiduals''': cell array with sum of squares residuals for each mode,
* description: cell array with text description of model, and
* '''description''': cell array with text description of model, and
* detail: sub-structure with additional model details and results.
* '''detail''': sub-structure with additional model details and results.
* pred = is a structure array, similar to model, that contains prediction results for new data fit to the TUCKER model.
* '''pred''' = is a structure array, similar to model, that contains prediction results for new data fit to the TUCKER model.
===Options===
===Options===
* ''options'' =  a structure array with the following fields:
* '''''options''''' =  a structure array with the following fields:
* display: [ {'on'} | 'off' ], governs level of display,
* '''display''': [ {'on'} | 'off' ], governs level of display,
* plots: [ {'final'} | 'all' | 'none' ], governs level of plotting,
* '''plots''': [ {'final'} | 'all' | 'none' ], governs level of plotting,
* weights: [], used for fitting a weighted loss function (discussed below),
* '''weights''': [], used for fitting a weighted loss function (discussed below),
* stopcrit: [1e-6 1e-6 10000 3600] defines the stopping criteria as [(relative tolerance) (absolute tolerance) (maximum number of iterations) (maximum time in seconds)],
* '''stopcrit''': [1e-6 1e-6 10000 3600] defines the stopping criteria as [(relative tolerance) (absolute tolerance) (maximum number of iterations) (maximum time in seconds)],
* init: [ 0 ], defines how parameters are initialized (see PARAFAC),
* '''init''': [ 0 ], defines how parameters are initialized (see PARAFAC),
* line: [ 0 | {1}] defines whether to use the line search {default uses it},
* '''line''': [ 0 | {1}] defines whether to use the line search {default uses it},
* algo: this option is not yet active,
* '''algo''': this option is not yet active,
* blockdetails: 'standard'
* '''blockdetails''': 'standard'
* missdat: this option is not yet active,
* '''missdat''': this option is not yet active,
* samplemode: [1], defines which mode should be considered the sample or object mode and
* '''samplemode''': [1], defines which mode should be considered the sample or object mode and
* constraints: {4x1 cell}, defines constraints on parameters (see PARAFAC). The first three cells define constraints on loadings whereas the last cell defines constraints on the core.
* '''constraints''': {4x1 cell}, defines constraints on parameters (see PARAFAC). The first three cells define constraints on loadings whereas the last cell defines constraints on the core.
The default options can be retreived using: options = tucker('options');.
The default options can be retreived using: options = tucker('options');.
===See Also===
===See Also===
[[datahat]], [[gram]], [[mpca]], [[outerm]], [[parafac]], [[parafac2]], [[tld]], [[unfoldm]]
[[datahat]], [[gram]], [[mpca]], [[outerm]], [[parafac]], [[parafac2]], [[tld]], [[unfoldm]]

Revision as of 20:58, 2 September 2008

Purpose

TUCKER analysis for n-way arrays.

Synopsis

model = tucker(x,ncomp,initval,options) %tucker model
pred = tucker(x,model) %application
options = tucker('options')

Description

TUCKER decomposes an array of order K (where K ? 3) into the summation over the outer product of K vectors. As opposed to PARAFAC every combination of factors in each mode are included (subspaces). Missing values must be NaN or Inf.

INPUTS

  • x = the multi-way array to be decomposed and
  • ncomp = the number of components to estimate, or
  • model = a TUCKER model structure.

OPTIONAL INPUTS

  • initval = if initval is the loadings from a previous TUCKER model are then these are used as the initial starting values to estimate a final model,
  • if initval is a TUCKER model structure then mode 1 loadings (scores) are estimated from x and the loadings in the other modes (see output pred),
  • ''' options = discussed below.

OUTPUTS

  • model = a structure array with the following fields:
  • modeltype: 'TUCKER',
  • datasource: structure array with information about input data,
  • date: date of creation,
  • time: time of creation,
  • info: additional model information,
  • loads: 1 by K+1 cell array with model loadings for each mode/dimension,
  • pred: cell array with model predictions for each input data block,
  • tsqs: cell array with T2 values for each mode,
  • ssqresiduals: cell array with sum of squares residuals for each mode,
  • description: cell array with text description of model, and
  • detail: sub-structure with additional model details and results.
  • pred = is a structure array, similar to model, that contains prediction results for new data fit to the TUCKER model.

Options

  • options = a structure array with the following fields:
  • display: [ {'on'} | 'off' ], governs level of display,
  • plots: [ {'final'} | 'all' | 'none' ], governs level of plotting,
  • weights: [], used for fitting a weighted loss function (discussed below),
  • stopcrit: [1e-6 1e-6 10000 3600] defines the stopping criteria as [(relative tolerance) (absolute tolerance) (maximum number of iterations) (maximum time in seconds)],
  • init: [ 0 ], defines how parameters are initialized (see PARAFAC),
  • line: [ 0 | {1}] defines whether to use the line search {default uses it},
  • algo: this option is not yet active,
  • blockdetails: 'standard'
  • missdat: this option is not yet active,
  • samplemode: [1], defines which mode should be considered the sample or object mode and
  • constraints: {4x1 cell}, defines constraints on parameters (see PARAFAC). The first three cells define constraints on loadings whereas the last cell defines constraints on the core.

The default options can be retreived using: options = tucker('options');.

See Also

datahat, gram, mpca, outerm, parafac, parafac2, tld, unfoldm