Saving and Loading your work in R


Use save command to save R objects related to any specific work that you are doing (to distinguish it from other things you or any other user might do in R on the same machine). You can save the environment in a file with extension .Rdata.

This can be loaded into R later using “load”.

This would help avoid other people removing your stuff inadvertantly. You can also transport this .Rdata file from one computer to another and load your R environment without having to run all the programs all over again.

For the purpose of the term paper, it will be of use to save your work into an .Rdata file and back it up (e-mail it to yourself?). Then you are not stuck to any particular machine and do not have to worry about somebody tampering with your work.


%d bloggers like this: