| descdata | R Documentation |
Computes descriptive statistics for selected numeric columns using efficient C++ routines.
descdata(data, cols = NULL, stats = 1:9, first = "variables",
cores = NULL, verbose = FALSE)
data |
A data frame, matrix, or numeric vector. If a vector is
supplied, it is treated as a single variable and the output's
first column is named |
cols |
Column indices or names of numeric variables to describe.
If |
stats |
Statistic selection from the nine available:
|
first |
Name for the first column of the output, which contains the variable identifiers. |
cores |
Number of CPU cores. |
verbose |
Logical; if |
The function accepts vectors, matrices, and data frames. Numeric columns are required. The calculation is performed entirely in C++ via Rcpp for speed.
A data frame with descriptive statistics for each variable.
Chun-Sheng Liang <chun-shengliang@qq.com>
1. Example data is from https://smear.avaa.csc.fi/download. It includes particle number concentrations in SMEAR I Varrio forest.
descdata(data, cols = 5:65)
descdata(data, cols = 5:65, stats = c(2, 7:9))
descdata(data, cols = 5:65, stats = c("na", "min", "max", "IQR"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.