I searched high and low for what, in my opinion, is a simple solution.
I have a large data frame, which I share by factors.
eqRegions <- split(eqDataAll, eqDataAll$SeismicRegion)
Now an object of the list of data frames by region is created; only 8. I would like to scroll through the list to make separate data frames using a different name.
I can do the following to convert list items to individual data frames, but I think there is a loop mechanism that is fast if I have many factors.
testRegion1 <- eqRegions[[1]]
testRegion3 <- eqRegions[[3]]
I can manually do the above, and it handles it perfectly, but if I have many regions, it is inefficient. I would like to do the following:
for (i in 1:length(eqRegions)) { region[i] <- as.data.frame(eqRegions[[i]]) }
I think the key is to define the area before the loop, but it continues to rewrite itself and not enlarge. Thank you very much.
source share