Example data
X<-matrix(c(rep(1,97),runif(97)) , nrow=97, ncol=2) y<-matrix(runif(97), nrow= 97 , ncol =1)
I have succeed in creating
The crossprod makes it surprisingly slower then the previous methods :
Previous method (14 secs mean on 50 iterations):
Crossprod method (16 secs mean on 50 iterations):