Best? Probably not. No money back if this deletes everything by mistake:
remove(list=ls()[sapply(ls(),function(n){!is.function(get(n))})])
As a function, maybe:
clearNonF=function(e=.GlobalEnv){remove(list=ls(e)[sapply(ls(e),function(n){!is.function(get(n))})],envir=e)}
clearNonF() will clear o
I think the subject says it all.
Thanks in advance,
KW
--
[[alternative HTML version deleted]]
__
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
2 matches
Mail list logo