Re: [R] List of Lists in For Loop

2014-07-15 Thread Adams, Jean
Munjal, Something like this should work: Digits = c(20, 30, 40, 50, 60) result = vector(length(Digits), mode="list") names(result) = Digits for(j in seq(Digits)) { a = vector(Digits[j], mode="list") b = vector(Digits[j], mode="list") for(i in 1:Digits[j]) { #Do Calculation a[[i]] = data.frame(#

[R] List of Lists in For Loop

2014-07-14 Thread Munjal Patel
Dear Experts, I have a one more doubt about making list of lists. Here is the simple code i have made. I am doing the following for only one digit=20 a=vector(20,mode="list") b=vector(20,mode="list") for (i in 1:20){ #Do Calculation a[[i]]=data.frame() b[[i]]=data.frame() } Now i have