Learn R Programming

⚠️There's a newer version (2.0-9) of this package.Take me there.

compositions (version 2.0-7)

Compositional Data Analysis

Description

Provides functions for the consistent analysis of compositional data (e.g. portions of substances) and positive numbers (e.g. concentrations) in the way proposed by J. Aitchison and V. Pawlowsky-Glahn.

Copy Link

Version

Install

install.packages('compositions')

Monthly Downloads

16,601

Version

2.0-7

License

GPL (>= 2)

Maintainer

K Gerald van den Boogaart

Last Published

January 9th, 2024

Functions in compositions (2.0-7)

Activity31

Activity patterns of a statistician for 20 days
Activity10

Activity patterns of a statistician for 20 days
Firework

Firework mixtures
Boxite

Compositions and depth of 25 specimens of boxite
Glacial

Compositions and total pebble counts of 92 glacial tills
Aar

Composition of glaciar sediments from the Aar massif (Switzerland)
Kongite

Compositions of 25 specimens of kongite
CompLinModCoReg

Compositional Linear Model of Coregionalisation
acompmargin

Marginal compositions in Aitchison Compositions
Metabolites

Steroid metabolite patterns in adults and children
ConfRadius

Helper to compute confidence ellipsoids
Coxite

Compositions, depths and porosities of 25 specimens of coxite
ShiftOperators

Shifts of machine operators
DiagnosticProb

Diagnostic probabilities
alr

Additive log ratio transform
balance

Compute balances for a compositional dataset.
AnimalVegetation

Animal and vegetation measurement
backtransform

Automatic common backtransformation for compositions
SimulatedAmounts

Simulated amount datasets
ClamEast

Color-size compositions of 20 clam colonies from East Bay
Skulls

Measurement of skulls
Hongite

Compositions of 25 specimens of hongite
SkyeAFM

AFM compositions of 23 aphyric Skye lavas
HotellingsTsq

Hotellings T square distribution
amounts-class

Class "amounts"
ClamWest

Color-size compositions of 20 clam colonies from West Bay
acomp

Aitchison compositions
acomparith

Power transform in the simplex
Sediments

Proportions of sand, silt and clay in sediments specimens
Hydrochem

Hydrochemical composition data set of Llobregat river basin water (NE Spain)
HouseholdExp

Household Expenditures
PogoJump

Honk Kong Pogo-Jumps Championship
barplot.acomp

Bar charts of amounts
apt

Additive planar transform
ccompgof

Compositional Goodness of fit test
Yatquat

Yatquat fruit evaluation
acomp-class

Class "acomp"
R2

R square
SerumProtein

Serum Protein compositions of blood samples
fitdirichlet

Fitting a Dirichlet distribution
Supervisor

Proportions of supervisor's statements assigned to different categories
cdt

Centered default transform
WhiteCells

White-cell composition of 30 blood samples by two different methods
binary

Treating binary and g-adic numbers
fitSameMeanDifferentVarianceModel

Fit Same Mean Different Variance Model
arrows3D

arrows in 3D, based on package rgl
boxplot

Displaying compositions and amounts with box-plots
biplot3D

Three-dimensional biplots, based on package rgl
aplus-class

Class "aplus"
as.data.frame

Convert "compositions" classes to data frames or matrices
aplus

Amounts analysed in log-scale
aplusarithm

vectorial arithmetic for data sets with aplus class
clr2ilr

Convert between clr and ilr, and between cpt and ipt.
axis3D

Drawing a 3D coordiante system to a plot, based on package rgl
ccomp-class

Class "ccomp"
ccomp

Count compositions
colorsForOutliers

Create a color/char palette or for groups of outliers
iit

Isometric identity transform
gsi.svdsolve

Internal function: Solves singular and non square equation systems
clo

Closure of a composition
cpt

Centered planar transform
compOKriging

Compositional Ordinary Kriging
gsi.textpanel

Internal function: A panel displaying a label only
ilr

Isometric log ratio transform
ClusterFinder1

Heuristics to find subpopulations of outliers
dist

Distances in variouse approaches
ellipses

Draw ellipses
CoDaDendrogram

Dendrogram representation of acomp or rcomp objects
compositions-package

tools:::Rd_package_title("compositions")
endmemberCoordinates

Recast amounts as mixtures of end-members
gsiinternal1

Internal functions of the compositions package
gsicall

Internal functions of the compositions package
groupparts

Group amounts of parts
cor.acomp

Correlations of amounts and compositions
coloredBiplot

A biplot providing somewhat easier access to details of the plot.
gsi.margin

Internal function: Compute a desired compositional margin
gsi.PrinBal

The canonical basis in the clr plane used for ilr and ipt transforms.
missing.compositions

The policy of treatment of missing values in the "compositions" package
logratioVariogram

Empirical variograms for compositions
gsi.diagGenerate

Internal functions: Generate a diagonal matrix
clr

Centered log ratio transform
gsigetBalStruct

An auxiliary functions to compute user-defined ilr and ipt transforms.
compositional-class

Class "compositional"
gsi.getD

Interal function: Get number of samples and number of parts in a compositional object
gsi.diagExtract

Internal functions: Get the diagonal of a matrix
gsi.merge2signary

Auxiliary functions to compute user-defined ilr and ipt transforms.
gausstest

Classical Gauss Test
lrvgram

vgram2lrvgram
missingsummary

Classify and summarize missing values in a dataset
getdetectionlimit

Gets the detection limit stored in the data set
gsipairs

Internal functions of the compositions package
geometricmean

The geometric mean
gsiinternal2

Internal functions of the compositions package
ilt

Isometric log transform
transformations from 'mixtures' to 'compositions' classes

Transformations from 'mixtures' to 'compositions' classes
ilrBase

The canonical basis in the clr plane used for ilr and ipt transforms.
gof

Compositional Goodness of fit test
IsMahalanobisOutlier

Checking for outliers
isoPortionLines

Isoportion- and Isoproportion-lines
gsi.drop

Internal functions: A conditional drop
gsi.eq

Internal function: Checking equality of IEEE special numbers
jura

The jura dataset
gsi.isSingleRow

Internal function: Can something be considered as a single multivariate data item?
outliersInCompositions

Analysing outliers in compositions.
kingTetrahedron

Ploting composition into rotable tetrahedron
kdeDirichlet

Density estimation on the simplex with Dirichlet kernel
meanrow

The arithmetic mean of rows or columns
gsi.csum

Internal function: row and column sums of matrices
gsiCoorInfo

Internal functions of the compositions package
pairwiseplot

Creates a paneled plot like pairs for two different datasets.
missingProjector

Returns a projector the the observed space in case of missings.
gsiinternal

Environment containing the old gsi functions
lines

Draws connected lines from point to point.
gsi.add

Internal functions: Parallel operations of single and multiple datasets
gsifiltercall

Calling from a function with the own parameters
gsi.expandrcomp

Internal function: Scaling rcomp
rDirichlet

Dirichlet distribution
gsi.addclass

Internal function: give a derived subclass to an object
rAitchison

Aitchison Distribution
mix.Read

Reads a data file in a mixR format
gsi.mapin01

Internal functions: Storing integers as reals
mvar

Metric summary statistics of real, amount or compositional data
plot3D

plot in 3D based on rgl
gsi.recode

Internal function: Recode missings with IEEE number and vice versa
gsi.simshape

Internal function: Reshape an object to the shape type of another
MahalanobisDist

Compute Mahalanobis distances based von robust Estimations
gsiinternal3

Internal functions of the compositions package
plot3Dacomp

3D-plot of compositional data
matmult

inner product for matrices and vectors
gsireset3D

Internal functions of the compositions package
princomp.aplus

Principal component analysis for amounts in log geometry
gsi2.invperm

Internal function: Invert a permutation
ipt

Isometric planar transform
is.acomp

Check for compositional data type
pairs

Pairs plot method for compositions
gsi.varwithlosts

Internal function: computes variance of compositional data set with missing/zero values
gsi.plain

Internal function: Convert to plain vector or matrix
gsiplotmargin

Internal functions of the compositions package
names

The names of the parts
acompscalarproduct

inner product for datasets with a vector space structure
idt

Isometric default transform
plotmissingsummary

Plot a Missing Summary
oneOrDataset

Treating single compositions as one-row datasets
normalize

Normalize vectors to norm 1
mean.acomp

Mean amounts and mean compositions
princomp.rcomp

Principal component analysis for real compositions
simulatemissings

Artifical simulation of various kinds of missings/polluted data
plot.aplus

Displaying amounts in scatterplots
norm

Vector space norm
outlierclassifier

Detect and classify compositional outliers.
plotlogratioVariogram

Empirical variograms for compositions
parametricMat

Unique parametrisations for matrices.
plot3Drplus

plot in 3D based on rgl
split

Splitting datasets in groups given by factors
pwlrPlot

Plots of pairwise logratio against a covariable.
princomp.rmult

Principal component analysis for real data
ternaryAxis

Axis for ternary diagrams
princomp.rplus

Principal component analysis for real amounts
NormalTests

Compositional Goodness of fit test
rcomp

Compositions as elements of the simplex embedded in the D-dimensional real space
rplus

Amounts i.e. positive numbers analysed as objects of the real vector space
rcomparithm

Arithmetic operations for compositions in a real geometry
replot

Modify parameters of compositional plots.
qqnorm

Normal quantile plots for compositions and amounts
rlnorm

The multivariate lognormal distribution
rplusarithm

vectorial arithmetic for data sets with rplus class
variation

Variation matrices of amounts and compositions
straight

Draws straight lines.
powerofpsdmatrix

power transform of a matrix
rmultmatmult

inner product for datasets with vector scale
outlierplot

Plot various graphics to analyse outliers.
rnorm

Normal distributions on special spaces
princomp.acomp

Principal component analysis for Aitchison compositions
vcovAcomp

Variance covariance matrix of parameters in compositional regression
variograms

Variogram functions
subsetting

Subsetting of compositions
varmlm

Residual variance of a model
perturbe

Perturbation of compositions
plot3Daplus

3D-plot of positive data
plot.acomp

Ternary diagrams
plot3Drmult

plot in 3D based on rgl
rcompmargin

Marginal compositions in real geometry
Read standard data files

Reads a data file in a geoeas format
ratioLoadings

Loadings of relations of two amounts
scalar

Parallel scalar products
rcomp-class

Class "rcomp"
zeroreplace

Zero-replacement routine
rmult

Simple treatment of real vectors
scale

Normalizing datasets by centering and scaling
summary.acomp

Summarizing a compositional dataset in terms of ratios
totals

Total sum of amounts
summary.aplus

Summaries of amounts
tryDebugger

Empirical variograms for compositions
rmultarithm

vectorial arithmetic for datasets in a classical vector scale
rMahalanobis

Compute distributions of empirical Mahalanobis distances based on simulations
pwlr

Pairwise log ratio transform
print.acomp

Printing compositional data.
rplus-class

Class "rplus"
summary.rcomp

Summary of compositions in real geometry
robustnessInCompositions

Handling robustness issues and outliers in compositions.
rmult-class

Class "rmult"
runif

The uniform distribution on the simplex
sumprojector

Compute the global projector to the observed subspace.
simplemissingplot

Ternary diagrams
rpois

Simulate count compositions without overdispersion
segments

Draws straight lines from point to point.
var.acomp

Variances and covariances of amounts and compositions
ult

Uncentered log transform
vgmFit

Compositional variogram model fitting
wrapped_functions

Standard R functions wrapped for compatibility
Bayesite

Permeabilities of bayesite
ArcticLake

Artic lake sediment samples of different water depth
Blood23

Blood samples