[R] automatic cleaning of workspace

Bert Gunter gunter.berton at gene.com
Tue Nov 28 01:42:23 CET 2006


I believe the usal advice here is to store data and associated functions
together in separate .Rdata datasets (workspaces) via ?save. You can ?load
them as needed. 

Bert Gunter
Genentech Nonclinical Statistics
South San Francisco, CA 94404


-----Original Message-----
From: r-help-bounces at stat.math.ethz.ch
[mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Leeds, Mark (IED)
Sent: Monday, November 27, 2006 3:30 PM
To: r-help at stat.math.ethz.ch
Subject: [R] automatic cleaning of workspace

I'm having that problem where I am sometimes using an object that's from
a previous workspace when I don't want to be doing that. I was thinking
of putting rm(objects=ls()) in my first.R function But, the problem with
doing this, is that it doesn't prompt you with "are you sure" and there
could be very rare cases where I don't want to delete the workspace ? Is
there a way to
make the cleaning of the workspace automatic but still prompt you ? I
guess I can always just try to remember to manually 
do rm(objects=ls())when I start up in whatever workspace I am in but I
don't think I can trust my memory. Thanks.
--------------------------------------------------------

This is not an offer (or solicitation of an offer) to buy/se...{{dropped}}

______________________________________________
R-help at stat.math.ethz.ch 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.



More information about the R-help mailing list