Learn R Programming

LaF (version 0.8.6)

colsum: Calculate simple statistics of column

Description

Methods for calculating simple statistics of columns of a file: mean, sum, standard deviation, range (min and max), and number of missing values.

Usage

colsum(x, ...)

# S4 method for laf colsum(x, columns, na.rm = TRUE, ...)

# S4 method for laf_column colsum(x, na.rm = TRUE, ...)

colmean(x, ...)

# S4 method for laf colmean(x, columns, na.rm = TRUE, ...)

# S4 method for laf_column colmean(x, na.rm = TRUE, ...)

colfreq(x, ...)

# S4 method for laf colfreq(x, columns, useNA = c("ifany", "always", "no"), ...)

# S4 method for laf_column colfreq(x, na.rm = TRUE, ...)

colrange(x, ...)

# S4 method for laf colrange(x, columns, na.rm = TRUE, ...)

# S4 method for laf_column colrange(x, na.rm = TRUE, ...)

colnmissing(x, ...)

# S4 method for laf colnmissing(x, columns, na.rm = TRUE, ...)

# S4 method for laf_column colnmissing(x, na.rm = TRUE, ...)

Arguments

x

an object of type laf or laf_column.

...

Currently ignored.

columns

a numeric vector with the columns for which the statistics should be calculated.

na.rm

whether or not to ignore missing values. By default missing values are ignored.

useNA

method with which to treat missing values: "ifany" adds a field containing the number of missing values if there are any; "always" will always add a field with the number of missing values even when there are none; "none" will never add a field containing the number of missing values.