Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

tableNA

Alternative Table Creation


Description

Count the occurrences of each factor level or value in a vector.

Usage

tableNA(x)

Arguments

x

numeric. An atomic vector or a factor.

Value

An object of class "tableNA", which is the result of tabulate() with three attributes:

  • type_of_x: the result of typeof(x);

  • is_factor_x: the result of is.factor(x);

  • levels: the result of levels(x).

The number of missing values is always reported.

Examples

tableNA(c(1,2,2,1,3))
tableNA(c(1,2,2,1,3, NA))

statip

Statistical Functions for Probability Distributions and Regression

v0.2.3
GPL-3
Authors
Paul Poncet [aut, cre], The R Core Team [aut, cph] (C function 'BinDist' copied from package 'stats'), The R Foundation [cph] (C function 'BinDist' copied from package 'stats'), Adrian Baddeley [ctb] (C function 'BinDist' copied from package 'stats')
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.