Corrspec

From Eigenvector Research Documentation Wiki
Jump to navigation Jump to search

Purpose

Resolves correlation spectroscopy maps.

Synopsis

model = corrspec(xspec,yspec,ncomp,options)
[purintx,purinty,purspecx,purspecy,maps] = corrspec(xspec,yspec,index,options)
[purintx,purinty,purspecx,purspecy,maps] = corrspec(xspec,yspec,model,options)

Description

CORRSPEC resolves a correlation map of two spectroscopies into the maps of individual components, their associated resolved spectra and the contributions ("concentrations") of the components in the original mixture spectra.

See Correlation Spectroscopy GUI for information on the interactive interface to this function.

Inputs

xspec : (2-way array class "double" or "dataset") x-matrix for dispersion matrix.
yspec : (2-way array class "double" or "dataset") y-matrix for dispersion matrix.
The third argument is one of the following:
ncomp : scalar, function will calculate first n resolved pure components.
index : nx2 matrix, each row indicates the X- and Y-position (i.e., index) to estimate the purity solution. If (ncomp) is empty [ ], the initial matrices will be estimated by CORRSPEC.
model : a model created by corrspec or corrspecgui. The model is used to calculate estimated xspec from yspec and vice versa. One of the arguments xspec and yspec can be empty.
options : see below.

Options

Optional input options is a structure array with the following fields:

  • plots_spectra : [ 'off' |{ 'on'} ] governs level of plotting for spectra.
  • plots_maps : [ 'off' | {'on'} ] governs level of plotting for maps.
  • offset : noise correction factor. If (offset) is a scalar, it defines the offset for both x and y. If (offset) is a two element vector it defines the offset for for x and y respectively.
  • inactivate : [ ] logical matrix of indices not to be used in purity calculation.
  • dispersion : [1] See (max) (below).
  • max : [3] If not given, only weight matrix will be calculated, otherwise select one of the options below:
max = 1: standardized, offset corrected
max = 2: length sqrt(nrows), offset corrected
max = 3: purity about mean, offset corrected
max = 4: purity about origin, offset corrected
max = 5: asynchronous, offset corrected

Outputs

purintx : resolved x contributions("concentrations").
purinty : resolved y contributions("concentrations").
purspecx : resolved x pure component spectra.
purspecy : resolved y pure component spectra.
map : cell array with ncomp resolved dispersion matrixes, each with size [size(yspec,2) by size(xspec,2)]
model : standard model structure, used for prediction (same pure variables on other data set) and add components to the model. The series of correlation maps resulting from the sequential elimination of components are stored in the field (.detail.matrix). See CORRSPECENGINE for detailed description of (matrix). The series of resolved correlation maps is stored in field (.detail.maps). Once a model has been calculated it can be used to predict x spectra from y spectra and vice versa.

Examples

load data_mid_IR
load data_near_IR 
corrspec(data_mid_IR,data_near_IR,4) 

See Also

corrspecengine, corrspecgui, dispmat, purity