Hello,
Consider this function for generalized ridge regression:
gre - function (X,y,D){
n - dim(X)[1]
p - dim(X)[2]
intercept - rep(1, n)
X - cbind(intercept, X)
X2D - crossprod(X,X)+ D
Xy - crossprod(X,y)
bth - qr.solve(X2D,
I think that is because X in your function has (n + 1) columns and D with
only n coluimns:
matrix(1:9, ncol = 3) + matrix(1:8, ncol = 2)
On Tue, Jul 7, 2009 at 2:30 PM, spime saby...@gmail.com wrote:
Hello,
Consider this function for generalized ridge regression:
gre - function (X,y,D){
Incomplete code leaves us able to do naught but guess;
Perhaps you are unaware that x != X
--
DW
On Jul 7, 2009, at 1:30 PM, spime wrote:
Hello,
Consider this function for generalized ridge regression:
gre - function (X,y,D){
n - dim(X)[1]
p - dim(X)[2]
intercept
Hi spime,
What is x? Did you have any other X defined in your R-session? Be aware
that R is case-sensitive.
Best,
Jorge
On Tue, Jul 7, 2009 at 1:30 PM, spime saby...@gmail.com wrote:
Hello,
Consider this function for generalized ridge regression:
gre - function (X,y,D){
n -
4 matches
Mail list logo