# Difference between revisions of "Dspls"

imported>Jeremy (→Description) |
|||

Line 6: | Line 6: | ||

:[reg,ssq,xlds,ylds,wts,xscrs,yscrs,basis] = dspls(x,y,ncomp,options) | :[reg,ssq,xlds,ylds,wts,xscrs,yscrs,basis] = dspls(x,y,ncomp,options) | ||

+ | |||

+ | Please note that the recommended way to build a PLS model using the Direct Scores algorithm from the command line is to use the Model Object. Please see [[EVRIModel_Objects | this wiki page on building models using the Model Object]]. | ||

===Description=== | ===Description=== | ||

Line 44: | Line 46: | ||

===See Also=== | ===See Also=== | ||

− | [[nippls]], [[pcr]], [[pls]], [[plsnipal]], [[simpls]] | + | [[nippls]], [[pcr]], [[pls]], [[plsnipal]], [[simpls]], [[EVRIModel_Objects]] |

## Latest revision as of 14:12, 3 January 2020

## Contents

### Purpose

Partial Least Squares computational engine using Direct Scores algorithm.

### Synopsis

- [reg,ssq,xlds,ylds,wts,xscrs,yscrs,basis] = dspls(x,y,ncomp,options)

Please note that the recommended way to build a PLS model using the Direct Scores algorithm from the command line is to use the Model Object. Please see this wiki page on building models using the Model Object.

### Description

Performs PLS regression using Direct Scores PLS algorithm as described in Andersson, "A comparison of nine PLS1 algorithms", J. Chemometrics, (www.interscience.wiley.com) DOI: 10.1002/cem.1248

This modified SIMPLS algorithm provides improved numerical stability for high numbers of latent variables.

Note: The regression matrices are ordered in **reg** such that each **ny** (number of Y-block variables) rows correspond to the regression matrix for that particular number of latent variables.

#### Inputs

**x**= X-block (predictor block) class "double".**y**= Y-block (predicted block) class "double".

#### Optional Inputs

**ncomp**= the number of latent variables to be calculated (positive integer scalar {default = rank of X-block}.

#### Outputs

**reg**= matrix of regression vectors.**ssq**= the sum of squares captured.**xlds**= X-block loadings.**ylds**= Y-block loadings.**wts**= X-block weights, currently returns empty.**xscrs**= X-block scores.**yscrs**= Y-block scores, currently returns empty.**basis**= the basis of X-block loadings.

### Options

options = a structure array with the following fields:

**display**: [ 'off' |{'on'}] governs display to command window**ranktest**: [ 'none' | 'data' | 'scores' | {'auto'} ] governs type of rank test to perform.

- 'data' = single test on X-block (faster with smaller data blocks and more components).
- 'scores' = test during regression on scores matrix (faster with larger data matricies).
- 'auto' = auto selection, or 'none' = assume sufficient rank.