basictable: Constructing a Frequency Table

Description Usage Arguments Value Examples

Description

Constructs a table which lists each unique entry in a vector and how many times it appears in the vector

Usage

1
basictable(input, order = TRUE, na.rm = FALSE)

Arguments

input

a vector of numbers

order

whether the modes should be sorted, with true being the default

Value

A vector

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
a <- c(3,1,3,2,2,4,2,3,4)
basictable(a)

b <- c(6,9,1,6,2,2)
basictable(b, order = FALSE)

d <- c(2,4,3,3,NA,NA,NA)
basictable(d, order = TRUE)

e <- c(2,4,3,3,NA,NA,NA)
modes(e, na.rm = TRUE)

Andy-McCarthy/BasicMath documentation built on May 27, 2019, 7:24 a.m.