cummode {cumstats}R Documentation

Cumulative Mode

Description

Returns a list whose elements are the cumulative statistical mode(s) of the elements of the argument.

Usage

cummode(x)

Arguments

x

a numeric vector.

Value

A list of the same length as x with numeric vectors. NA values are also counted.

Author(s)

Arturo Erdely.

References

Kotz, S., Balakrishnan, N., Read, C.B, Vidakovic, B., Johnson, N.L. (2006) Encyclopedia of Statistical Sciences. Wiley, New Jersey.

See Also

Mode

Examples

cummode(c(rep(1, 2), rep(12, 5), rep(44, 3), rep(8, 5), 55))

cummode(c(rep(1, 2), rep(12, 5), rep(44, 3), rep(8, 5), rep(NA, 7), 55))

cummode(runif(5))

cummode(c(rep("a", 2), rep("b", 5), rep("d", 3), rep("e", 5), rep(NA, 5)))

[Package cumstats version 1.0 Index]