easyCODA-package: Compositional Data Analysis in Practice

Description Details Author(s) References See Also Examples

Description

Univariate and multivariate methods for compositional data analysis, based on logratios. The package implements the approach in the book Compositional Data Analysis in Practice by Michael Greenacre (2018), where accent is given to simple pairwise logratios. Selection can be made of logratios that account for a maximum percentage of logratio variance. Various multivariate analyses of logratios are included in the package.

Details

The DESCRIPTION file: This package was not yet installed at build time.

Index: This package was not yet installed at build time.

Author(s)

Michael Greenacre

Maintainer: Michael Greenacre <michael.greenacre@upf.edu>

References

Greenacre, Michael (2018) Compositional Data Analysis in Practice. Chapman & Hall / CRC Press

See Also

ca

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
# Roman cups glass compositions
data(cups)
# unweighted logratio analysis
cups.uLRA <- LRA(cups, weight=FALSE)
PLOT.LRA(cups.uLRA)
# weighted logratio analysis
cups.wLRA <- LRA(cups)
PLOT.LRA(cups.wLRA)
# author data set from the ca package
data(author)
which(author == 0, arr.ind = TRUE)
# row 5 (Farewell to Arms) and col 17 (Q) has a zero
# replace it with 0.5 for the logratio analysis
author[5,17] <- 0.5
# LRA (weighted by default)
# Here the ca plot function plot.ca is used
plot(LRA(author))

Example output

Loading required package: ca
Loading required package: vegan
Loading required package: permute
Loading required package: lattice
This is vegan 2.5-7
Loading required package: ellipse

Attaching package:ellipseThe following object is masked frompackage:graphics:

    pairs

                             row col
farewell to arms (hemingway)   5  17
Warning: The row sums of this matrix are not constant, so this may not be a compositional data matrix
         Nevertheless, the method is still valid and continues since all the data values are positive
         If this was not intended, please supply a valid compositional table with constant row sums

easyCODA documentation built on Sept. 20, 2020, 1:07 a.m.