statsByGroup {GCDkit}R Documentation

Statistics by groups

Description

Calculates simple descriptive statistics for individual columns of the given data matrix; optionally this can be done for each of the groups separately.

Usage

statsByGroup(data = WR, groups = groups)

Arguments

data

numeric data matrix.

groups

a vector, in which is specified, for each sample, a group it belongs to.

Details

The function returns a list containing the calculated statistical parameters respecting the desired grouping. The statistical summary involves number of observations, missing values, mean, standard deviation, minimum, 25% quartile, median (= 50% quartile), 75% quartile and maximum. This is a core function invoked both by summarySingle and summarySingleByGroup.

Value

results

a list with the results for individual groups

Author(s)

Vojtech Janousek, vojtech.janousek@geology.cz

See Also

summarySingle

statistics

summaryAll

summaryByGroup

Examples

statsByGroup(WR)

statsByGroup(WR[,LILE])

[Package GCDkit version 4.1 Index]