[R] Batch files in R
gisar at nus.edu.sg
Thu Jul 3 05:32:21 CEST 2003
You can use save(object1, file="lalala.1"), save(object1,
file="lalala.2"), ... and the use load() to restore the object1 and
object2. Or if you have many objects in a simulation to save, you can
save all objects using save.image("sim1.result.R").
Another option is to use write.table or zz <- file("lalal1.txt"); cat(
... , file=zz) etc if you want a human-readable form of your output.
It would be a good idea to use the compress=TRUE option in save() and R
From: Johanna Hardin [mailto:Jo.Hardin at pomona.edu]
Sent: Thursday, July 03, 2003 2:24 AM
To: 'r-help at lists.R-project.org'
Subject: [R] Batch files in R
When I submit more than one batch file (same programs, different
parameter values, huge simulations, different result names) the only
results that get saved are from the *last* batch file to finish. They
are all being run in the same subdirectory (so same .RData file?)
R --save BATCH infile outfile
and I've also put
at the end of the program, but it will still only save results from one
program. Is there any way to get all the results to save without
putting each of the batch files in a separate directory?
Department of Mathematics & Computer Science
jo.hardin at pomona.edu
[[alternative HTML version deleted]]
R-help at stat.math.ethz.ch mailing list
More information about the R-help