Purityengine

From Eigenvector Documentation Wiki

Jump to: navigation, search

Contents

Purpose

Calculation of pure variables.

Synopsis

[purity_index,purity_values,length_values]=purityengine(data,base,offset)

Description

PURITYENGINE calculates the column index of the variable in data that has the largest angle with respect to base. For the first pure variable base should be empty: the program then substitutes a vector of ones for base. base generally contains previously determined pure variables. The argument offset gives a lower weight to variables with low values. Its value is based on a percentage of the maximum value of the mean of data. A typical value is 3.

The output arguments purity_values contains the purity values for all the variables and can be plotted as the "purity spectrum". The argument length_values contains the purity_values multiplied by the length of the variables. This results in a "length spectrum" that is easier to relate to the original data than the purity spectrum

Examples

Determination of three pure variables of a matrix data for an offset of 3

[purity_index,purity_values,length_values]=purityengine(data,[],3);
purity_array=[purity_index];
[purity_index,purity_values,length_values]=purityengine(data,...
data(:,purity_array),3);
purity_array=[ purity_array purity_index];
[purity_index,purity_values,length_values]=purityengine(data,...
data(:,purity_array),3);
purity_array=[ purity_array purity_index];

The indices of the three pure variables are in purity_array. A plot of purity_values and length_values shows the successive stages of the pure variable extraction.

Algorithm

The calculations are based on the MATLAB function subspace. The angle of every variable in the data is calculated with respect to the base: subspace(base,data(:,i))

See Also

purity

Views
Personal tools