Re: [R] In ppls package kernel method is unsupported?

2011-03-22 Thread Łukasz Ręcławowicz
W dniu 22 marca 2011 10:27 u¿ytkownik £ukasz Rêc³awowicz <
lukasz.reclawow...@gmail.com> napisa³:

>
> penalized.pls.kernel(Z,y,M=lambda*P,ncomp=number.comp) # But using
> directly, coefficients are different.
>

I see me error P=!M, but still results are the same...

 p <- ncol(Z)
Minv <- diag(p) + P
M <- solve(Minv)
penalized.pls.default(Z,y,M=M,ncomp=number.comp)
penalized.pls.kernel(Z,y,M=M,ncomp=number.comp)



-- 
Mi³ego dnia

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


[R] In ppls package kernel method is unsupported?

2011-03-22 Thread Łukasz Ręcławowicz
require(ppls)
data(BOD)
X<-BOD[,1]
y<-BOD[,2]
Xtest=seq(min(X),max(X),length=200)
dummy<-X2s(X,Xtest,deg=3,nknot=20)
Z<-dummy$Z
Ztest<-dummy$Ztest
size<-dummy$sizeZ
P<-Penalty.matrix(size,order=2)
lambda<-200
number.comp<-3

penalized.pls(Z,y,P=lambda*P,ncomp=number.comp)$coefficients # By default
kernel=F
penalized.pls(Z,y,P=lambda*P,ncomp=number.comp,kernel=TRUE)$coefficients #
Same as above...?!
penalized.pls.kernel(Z,y,M=lambda*P,ncomp=number.comp) # But using directly,
coefficients are different.

-- 
Mi³ego dnia

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.