4

In a .Rproj.user folder there is a folder named "B1B3AE79/suspended-session-data." Inside that folder is an object named "environment" taking up over 60 GB of space. I need to clean this up. I have saved .Rmd scripts and datasets elsewhere.

What would I risk by deleting "B1B3AE79/suspended-session-data/environment?"

johnckane
  • 645
  • 8
  • 18
  • 1
    I verified that datasets were saved and even cleared the environment in RStudio server with no change to the size of the environment object stored in the referenced filepath. I then deleted the environment object and cleared the space. No deleterious effects so far. But if someone has any insight into these objects stored in the .Rproj.user folder I'd be interested in learning something new. – johnckane May 17 '17 at 20:54

1 Answers1

8

When RStudio detects that an R session has been idle for a period of time, it will suspend that session -- this effectively amounts to saving the R session state (global environment, attached packages, and so on) and then re-loading it when you next return to that session.

As you've seen, since that suspend also implies saving the global environment to disk, this implies that large data objects will potentially be saved when the session is suspended as well.

Deleting that data implies that a 'suspended' R session will not be able to successfully restore the previous session -- whether or not that is a severe issue likely depends on how you use R / RStudio, but as long as you can easily re-read or re-create your workspace from saved source files, it shouldn't be too big a problem.

Kevin Ushey
  • 20,530
  • 5
  • 56
  • 88