> -Original Message-
> From: r-help-boun...@r-project.org
> [mailto:r-help-boun...@r-project.org] On Behalf Of Ronggui Huang
> Sent: Monday, August 24, 2009 9:26 PM
> To: Steven Kang
> Cc: r-help@r-project.org
> Subject: Re: [R] Removing objects from workspace
>
It depends.
If there are patterns in the names, you can make use of pattern
argument of ls(). For example,
> x1="a";x2="b";x3="c"
> ls(pattern="x[1-2]")
[1] "x1" "x2"
> ls(pattern="x[^1-2]")
[1] "x3"
# to remove x1-x3
>rm(list=ls(pattern="x[1-2]"))
More generally, if you want to remove all butx,x
Hi all,
I am currently woking with hundreds of objects in workspace and whenever I
invoke ls() to observe the names of the objects, there are too much of
unnecessary variables.
For example, if I only require say 3 or 4 objects from hundreds of objects
in workspace, are there any methods that may
3 matches
Mail list logo