If your specified objects have a certain pattern, you can use the parameter "pattern" in ls() to remove or keep it.
rm(list=ls(..., pattern="your_pattern"))
If not, possibly you have to manually specify them.

On 2010-8-24 3:00, Cheng Peng wrote:
How to remove all R objects in the RAM except for a few specified ones?
rm(list=ls()) removes all R objects in the R work space.

Another question is that whether removing all R objects actually releases
the RAM? Thanks.


______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to