Re: [R] create data frame with coefficients from many regressions

2013-07-22 Thread Rui Barradas
Hello, Using Arun's data example, you can also do the following. set.seed(28) dat1<- as.data.frame(matrix(sample(1:20,100,replace=TRUE),ncol=10)) set.seed(49) dat2<- as.data.frame(matrix(sample(40:80,100,replace=TRUE),ncol=10)) lm.list <- lapply(seq_len(ncol(dat1)), function(i) lm(dat1[,i] ~

Re: [R] create data frame with coefficients from many regressions

2013-07-22 Thread arun
1 PM Subject: [R] create data frame with coefficients from many regressions > Hi ! > > I want to ask if somebody knows the way to create data frame with > coefficients from many regressions > I regress the first column from ret against the first columns from median, > then the

[R] create data frame with coefficients from many regressions

2013-07-22 Thread iza.ch1
> Hi ! > > I want to ask if somebody knows the way to create data frame with > coefficients from many regressions > I regress the first column from ret against the first columns from median, > then the second with the second and so on. > This is the code used for regression > > i<-1:6 > lappl