[R] functions
Duncan Murdoch
murdoch at stats.uwo.ca
Sun Oct 10 00:56:29 CEST 2004
On Sat, 9 Oct 2004 18:12:20 -0400, "Benjamin M. Osborne"
<Benjamin.Osborne at uvm.edu> wrote:
>Does anyone know of a list of functions that R already "knows?" I can't seem to
>find this anywhere in the help documentation. For example, I want to count the
>number of occurences of a certain value in a column of a data frame: What do I
>have to do to tell R to "Count?"
There are several such lists. The one you want is probably the one
the help system uses. For example,
help.search('count')
lists a number of functions that count various things. I don't think
any of them is exactly what you want, which could be accomplished in a
couple of ways:
table(x)
gives counts of all the different values in x;
length(x[x==3])
gives the count of occurences of 3 in x.
Duncan Murdoch
More information about the R-help
mailing list