sopls sparse orthonormalized partial least squares.
DESCRIPTION
sopls estimates a model of the form Z = PX + C, Y = QZ.
lambda_min specifies the fraction of the maximal lambda value (computed
by glmnet) for which the output will be returned.
alpha specifies the balance between ridge regression (alpha=0) and lasso
regression (alpha=1).
The number of steps taken to traverse the regularization path is given by nlambda.
if nlambda=0 then standard partial least squares will be used.
pmax specifies the maximum number of variables included in the solution.
nhidden specifies the number of used components. If it is decreased
during testing then the restricted number of components will be used
(only in case of sparse partial least squares!)
EXAMPLE
load data;
p = dml.sopls('nhidden',3,'verbose',true);
p = p.train(X(1:40,1:10),I(1:40,:));
r = p.test(X(41:50,1:10));
for j=1:10, subplot(2,5,j); imagesc(reshape(r(j,:),[16 16])); colormap(gray); axis off, end
figure
for j=1:10, subplot(2,5,j); imagesc(reshape(I(40+j,:),[16 16])); colormap(gray); axis off, end
v = dml.enet.lambdapath(X,Y,'gaussian',50,1e-3);
m = dml.gridsearch('cv',dml.crossvalidator('type','split','stat','correlation','mva',dml.enet('family','gaussian','restart',false)),'vars','L1','vals',v,'verbose',true);
p = dml.sopls('nhidden',3,'verbose',true,'regularizer',m);
p = p.train(X(1:40,1:10),I(1:40,:));
r = p.test(X(41:50,1:10));
for j=1:10, subplot(2,5,j); imagesc(reshape(r(j,:),[16 16])); colormap(gray); axis off, end
figure
for j=1:10, subplot(2,5,j); imagesc(reshape(I(40+j,:),[16 16])); colormap(gray); axis off, end
REFERENCE
When using this method please refer to the following:
van Gerven MAJ, Heskes T. Sparse Orthonormalized Partial Least Squares. In: BNAIC. 2010.
DEVELOPER
Marcel van Gerven (m.vangerven@donders.ru.nl), Tom Heskes (tomh@cs.ru.nl)