Skip to content
Prev 22687 / 398502 Next

How to run R to generate graphics (jpeg) files dynamically ?

Do you want to call the external files within R?  If so:
  source("foo.R")
will do as long as you set the working directory to be the directory with "foo.R". 

If you want to invoke in batch mode, then depending on your platform (from your description on Rgui, I take it you're on Windows), you will do:
  Rcmd BATCH foo.R
it will then run all the commands in foo.R and save the output in foo.Rout.
What do you mean by processed data?  If you meant "graphs", then take a look at:
  ?jpeg
if you mean all the commands and their results, they will be stored (if you run in BATCH mode) in *.Rout, which is plain ASCII file.


-----------------------------------
Ko-Kang Kevin Wang
Statistical Analysis Division Leader
Software Developers' Klub (SDK)
University of Auckland
New Zealand

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._