I am relatively new to R and have a complicated situation to solve. I have uploaded a list of over 1000 data frames into R and called this list x. What I want to do is take
You can use lapply and pass indices as follows:
lapply
ids <- seq(3, 54, by=3) out <- do.call(rbind, lapply(ids, function(idx) { t <- unlist(x[[idx]][, -1]) c(mean(t), var(t)) }))