Hi,
depending on what you do and how (and why) you save objects in RData
files in the first place, you might be interested in knowing of the
loadObject()/saveObject() methods of R.utils, as well as
loadCache()/saveCache() in R.cache.
The R.utils methods are basically "clever" wrappers around
load
set
of objects whose names are listed in a character array (as returned
by load) ?
Thank you!
-- TMK --
212-460-5430 home
917-656-5351 cell
> Date: Mon, 10 Dec 2007 14:31:19 -0500
> From: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> CC: [EMAIL PROTECTED]
> Subject: Re: [R
500> From: [EMAIL PROTECTED]> To: [EMAIL
> PROTECTED]> CC: [EMAIL PROTECTED]> Subject: Re: [R] Reading through a group
> of .RData files> > note that load() returns, invisibly, a string with the
> names of the > objects that were loaded. something in the lines of:&g
On Mon, 10 Dec 2007, Talbot Katz wrote:
>
> Hi.
>
> I have a procedure that reads a directory, loops through a set of
> particular .RData files, loading each one, and feeding its object(s)
> into a function, as follows:
>
> cvListFiles<-list.files(fnDir);
> for(i in grep(paste("^",pfnStub,".*\\.
note that load() returns, invisibly, a string with the names of the
objects that were loaded. something in the lines of:
myObj <- load(file.path(fnDir, cvListFiles[i]))
myFunction(get(myObj))
rm(list=myObj)
might be closer to what you want.
moreover, if length(myObj) > 1, you might want sth lik
Hi.
I have a procedure that reads a directory, loops through a set of particular
.RData files, loading each one, and feeding its object(s) into a function, as
follows:
cvListFiles<-list.files(fnDir);
for(i in grep(paste("^",pfnStub,".*\\.RData$",sep=""),cvListFiles)){
load(paste(fnDir,cvList
6 matches
Mail list logo