I am experimenting with some of the common r functions.
I had a question re:using gsub (or some similar functions) on the contents of
a list.
I want to design a function that looks at everything contained din a list,
and anytime it finds the text string pattern replace it with x. I also
wish
On Wed, 2007-05-16 at 09:25 -0700, new ruser wrote:
I am experimenting with some of the common r functions.
I had a question re:using gsub (or some similar functions) on the
contents of a list.
I want to design a function that looks at everything contained din a
list, and anytime it finds
On 5/16/07, Marc Schwartz [EMAIL PROTECTED] wrote:
On Wed, 2007-05-16 at 09:25 -0700, new ruser wrote:
I am experimenting with some of the common r functions.
I had a question re:using gsub (or some similar functions) on the
contents of a list.
I want to design a function that looks at
On Wed, 2007-05-16 at 13:18 -0400, Gabor Grothendieck wrote:
On 5/16/07, Marc Schwartz [EMAIL PROTECTED] wrote:
On Wed, 2007-05-16 at 09:25 -0700, new ruser wrote:
I am experimenting with some of the common r functions.
I had a question re:using gsub (or some similar functions) on the
Here is a recursive function you could try. Here f has been defined only to
convert character variables. Modify to suit.
recurse - function(x, f) {
if (length(x) == 0) return(x)
if (is.list(x)) for(i in seq_along(x)) x[[i]] - recurse(x[[i]], f)
else x - f(x)
x
}
f - function(x) if