1

I am wondering if there is any way to get the list of variables in R workspace file (.RData) before loading it? I mean any function which could look like: ls('/Users/xxx/workspace.RData'); Thanks a lot for your help! Tomek

  • 1
    Why do you want to do this? I think I have an idea of why you want to do it and there is a better way to do what you want that doesn't require it but it would be nice to verify that my suspicion is correct. – Dason Oct 28 '14 at 19:36
  • See [this post](http://stackoverflow.com/a/8703024/489704). – jbaums Oct 28 '14 at 19:43
  • I've my own software that communicates with R via Rserve package. When loading a saved workspace I'd like to check which variables are new. Of course, I can check `ls()` before loading workspace and after it and compare them using `setdiff`, but if I had a varible e.g. x = 5, and after loading workspace with x = 7, the the described method won't detect the change. – Tomasz Kubik Oct 29 '14 at 09:04

0 Answers0