Jean Eid wrote:> This is probably a weird question but I need to know if there is a way...
>
> I run an R batch job without saving the variables at each step to the
> disk. Is there a way to invoke another session of R and link it to the
> same environment for read only.
>
> The problem is that I am running optim with every step getting the
> parameters into the global env using <<- However, I forgot to issue a
> save(list=ls(),...) right after so I can load and see how the parameters
> are changing. It's been couple of days and it is still running so I am
> hoping that I can invoke another session of R and link it to the
> environment of the batch session. Does this sound totally ridiculous ?
>
> it is a debian machine with R 2.1.1
If you happened to have compiled R with debug information, you might be
able to use gdb or another debugger to examine variables in the running
process, but you probably didn't, and it's probably easier to kill the
job, fix it, and start it again, than it would be to learn how to see
the active variables using gdb.
Duncan Murdoch