statistics {GCDkit}R Documentation

Basic descriptive statistics

Description

Calculates simple descriptive statistics respecting grouping. Optionally can be plotted boxplots and/or histograms.

Usage

statistics(where = WR, elems, groups = rep("", nrow(where)), 
which = "", boxplots = TRUE, histograms = TRUE, 
print.table = TRUE, sub = "")

Arguments

where

name of the data matrix

elems

list of elements/oxides

groups

grouping information, default=no grouping

which

which of the groups are to be shown

boxplots

logical, plot boxplots?

histograms

logical, plot histograms?

print.table

logical, print the resulting table?

sub

subtitle for the histograms/boxplots

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.

Value

results

a list with the results for individual groups

Author(s)

Vojtech Janousek, vojtech.janousek@geology.cz

See Also

summarySingle summarySingleByGroup summaryAll summaryByGroup

Examples

    i<-statistics(elems=c("SiO2","TiO2","Al2O3","Na2O","K2O"),
    boxplots=FALSE,histograms=FALSE)

[Package GCDkit version 4.0 Index]