I would like to save a whole bunch of relatively large data frames while minimizing the space that the files take up. When opening the files, I need to be able to control what names they are given in the workspace.
Basically I'm looking for the symantics of dput and dget but with binary files.
Example:
n<-10000
for(i in 1:100){
dat<-data.frame(a=rep(c("Item 1","Item 2"),n/2),b=rnorm(n),
c=rnorm(n),d=rnorm(n),e=rnorm(n))
dput(dat,paste("data",i,sep=""))
}
##much later
##extract 3 random data sets and bind them
for(i in 1:10){
nums<-sample(1:100,3)
comb<-rbind(dget(paste("data",nums[1],sep="")),
dget(paste("data",nums[2],sep="")),
dget(paste("data",nums[3],sep="")))
##do stuff here
}