A couple of ways:
List.glm <- list()
for(i in 1:n) list.glm[[i]] <-glm(,,,)
OR
List.glm <- lapply(1:n, function(x) glm(,,,))
On Fri, Oct 9, 2009 at 7:54 AM, P.Branco wrote:
>
> Hello,
>
> I am trying to run a for-loop in which I want to add glm output objects
> sequentially into a list. I d
Hello,
I am trying to run a for-loop in which I want to add glm output objects
sequentially into a list. I do not know how to give names to each object in
a list. I tried this :
List.glm <- list()
for(i in 1:n)
list.glm <- list(list.glm, glm(,,,))
but it is obviously unsuited…
Best rega
2 matches
Mail list logo