Learn R Programming

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

Compositional (version 3.8)

Compositional Data Analysis

Description

Regression, classification, contour plots, hypothesis testing and fitting of distributions for compositional data are some of the functions included. The standard textbook for such data is John Aitchison's (1986) "The statistical analysis of compositional data". Relevant papers include a) Tsagris M.T., Preston S. and Wood A.T.A. (2011) A data-based power transformation for compositional data. Fourth International International Workshop on Compositional Data Analysis. b) Tsagris M. (2014). The k-NN algorithm for compositional data: a revised approach with and without zero values present. Journal of Data Science, 12(3):519--534. c) Tsagris M. (2015). A novel, divergence based, regression for compositional data. Proceedings of the 28th Panhellenic Statistics Conference, 15-18 April 2015, Athens, Greece, 430--444. d) Tsagris M. (2015). Regression analysis with compositional data containing zero values. Chilean Journal of Statistics, 6(2):47--57. e) Tsagris M., Preston S. and Wood A.T.A. (2016). Improved supervised classification for compositional data using the alpha-transformation. Journal of Classification, 33(2):243--261. . f) Tsagris M., Preston S. and Wood A.T.A. (2017). Nonparametric hypothesis testing for equality of means on the simplex. Journal of Statistical Computation and Simulation, 87(2): 406--422. g) Tsagris M. and Stewart C. (2018). A Dirichlet regression model for compositional data with zeros. Lobachevskii Journal of Mathematics, 39(3): 398--412. . h) Alenazi A. (2019). Regression for compositional data with compositional data as predictor variables with or without zero values. Journal of Data Science, 17(1): 219--238. . i) Tsagris M. and Stewart C. (2019). A folded model for compositional data analysis. . j) Tsagris M., Alenazi A. and Stewart C. (2020). The alpha-k-NN regression for compositional data. . We further include functions for percentages (or proportions).

Copy Link

Version

Install

install.packages('Compositional')

Monthly Downloads

1,183

Version

3.8

License

GPL (>= 2)

Maintainer

Michail Tsagris

Last Published

March 16th, 2020

Functions in Compositional (3.8)

Estimation of the value of alpha via the profile log-likelihood

Estimation of the value of \(\alpha\) via the alfa profile log-likelihood
The alpha-transformation

The \(\alpha\)-transformation
The alpha-k-NN regression with compositional predictor variables

The \(\alpha\)-k-NN regression with compositional predictor variables
Cross validation for the alpha-k-NN regression for compositional response data

Cross validation for the \(\alpha\)-k-NN regression for compositional response data
The alpha-k-NN regression for compositional response data

The \(\alpha\)-k-NN regression for compositional response data
Estimation of the value of alpha in the folded model

Estimation of the value of \(\alpha\) in the folded model
Multivariate or univariate regression with compositional data in the covariates side using the alpha-transformation

Multivariate or univariate regression with compositional data in the covariates side using the \(\alpha\)-transformation
Compositional-package

Compositional Data Analysis
Tuning the value of alpha in the alpha-regression

Tuning the value of \(\alpha\) in the \(\alpha\)-regression
MLE of distributions defined in the (0, 1) interval

MLE of distributions defined in the (0, 1) interval
Regression with compositional data using the alpha-transformation

Regression with compositional data using the \(\alpha\)-transformation
Regularised and flexible discriminant analysis for compositional data using the alpha-transformation

Regularised and flexible discriminant analysis for compositional data using the \(\alpha\)-transformation
The alpha-distance

The \(\alpha\)-distance
Cross validation for the alpha-k-NN regression with compositional predictor variables

Cross validation for the \(\alpha\)-k-NN regression with compositional predictor variables
The additive log-ratio transformation and its inverse

The additive log-ratio transformation and its inverse
Mixture model selection via BIC

Mixture model selection via BIC
Beta regression

Beta regression
Inverse of the alpha-transformation

Inverse of the \(\alpha\)-transformation
MLE of the folded model for a given value of alpha

MLE of the folded model for a given value of \(\alpha\)
Fast estimation of the value of alpha

Fast estimation of the value of \(\alpha\)
All pairwise additive log-ratio transformations

All pairwise additive log-ratio transformations
Cross validation for the ridge regression with compositional data as predictor using the alpha-transformation

Cross validation for the ridge regression with compositional data as predictor using the \(\alpha\)-transformation
The k-nearest neighbours using the alpha-distance

The k-nearest neighbours using the \(alpha\)-distance
Cross validation for the regularised and flexible discriminant analysis with compositional data using the alpha-transformation

Cross validation for the regularised and flexible discriminant analysis with compositional data using the \(\alpha\)-transformation
The k-NN algorithm for compositional data

The k-NN algorithm for compositional data
Tuning the number of PCs in the PCR with compositional data using the alpha-transformation

Tuning the number of PCs in the PCR with compositional data using the \(\alpha\)-transformation
Cross validation for some compositional regression models

Cross validation for some compositional regression models
Ridge regression with the alpha-transformation plot

Ridge regression plot
Contour plot of the t distribution in S^2

Contour plot of the t distribution in \(S^2\)
Estimating location and scatter parameters for compositional data

Estimating location and scatter parameters for compositional data
Ridge regression with compositional data in the covariates side using the alpha-transformation

Ridge regression with compositional data in the covariates side using the \(\alpha\)-transformation
Contour plot of the kernel density estimate in S^2

Contour plot of the kernel density estimate in \(S^2\)
Divergence matrix of compositional data

Divergence matrix of compositional data
Fitting a Dirichlet distribution via Newton-Rapshon

Fitting a Dirichlet distribution via Newton-Rapshon
Multivariate regression with compositional data

Multivariate regression with compositional data
Density values of a Dirichlet distribution

Density values of a Dirichlet distribution
Hotelling's multivariate version of the 2 sample t-test for Euclidean data

Hotelling's multivariate version of the 2 sample t-test for Euclidean data
Dirichlet regression

Dirichlet regression
Hypothesis testing for two or more compositional mean vectors

Hypothesis testing for two or more compositional mean vectors
Projection pursuit regression for compositional data

Projection pursuit regression for compositional data
James multivariate version of the t-test

James multivariate version of the t-test
Exponential empirical likelihood hypothesis testing for two mean vectors

Exponential empirical likelihood hypothesis testing for two mean vectors
Kullback-Leibler divergence and Bhattacharyya distance between two Dirichlet distributions

Kullback-Leibler divergence and Bhattacharyya distance between two Dirichlet distributions
Principal component generalised linear models

Principal component generalised linear models
Log-likelihood ratio test for a Dirichlet mean vector

Log-likelihood ratio test for a Dirichlet mean vector
Exponential empirical likelihood for a one sample mean vector hypothesis testing

Exponential empirical likelihood for a one sample mean vector hypothesis testing
Multivariate analysis of variance

Multivariate analysis of variance
Contour plot of a Dirichlet distribution in S^2

Contour plot of a Dirichlet distribution in \(S^2\)
MLE for the multivarite t distribution

MLE for the multivarite t distribution
Helper functions for the Kullback-Leibler regression

Helper functions for the Kullback-Leibler regression
Tuning of the k-NN algorithm for compositional data

Tuning of the k-NN algorithm for compositional data
Empirical likelihood for a one sample mean vector hypothesis testing

Empirical likelihood for a one sample mean vector hypothesis testing
Gaussian mixture models for compositional data

Gaussian mixture models for compositional data
Tuning of the projection pursuit regression for compositional data

Tuning of the projection pursuit regression for compositional data
Fitting a Dirichlet distribution

Fitting a Dirichlet distribution
Divergence based regression for compositional data with compositional data in the covariates side using the alpha-transformation

Divergence based regression for compositional data with compositional data in the covariates side using the \(\alpha\)-transformation
Multivariate linear regression

Multivariate linear regression
Tuning the principal components with GLMs

Tuning the principal components with GLMs
Divergence based regression for compositional data

Divergence based regression for compositional data
Multivariate analysis of variance (James test)

Multivariate analysis of variance (James test)
Contour plot of a Gaussian mixture model in S^2

Contour plot of a Gaussian mixture model in \(S^2\)
Multivariate kernel density estimation

Multivariate kernel density estimation
The Frechet mean for compositional data

The Frechet mean for compositional data
The Helmert sub-matrix

The Helmert sub-matrix
Quasi binomial regression for proportions

Quasi binomial regression for proportions
Tuning of the divergence based regression for compositional data with compositional data in the covariates side using the alpha-transformation

Tuning of the divergence based regression for compositional data with compositional data in the covariates side using the \(alpha\)-transformation
Generate random folds for cross-validation

Generate random folds for cross-validation
Helper Frechet mean for compositional data

Helper Frechet mean for compositional data
Empirical likelihood hypothesis testing for two mean vectors

Empirical likelihood hypothesis testing for two mean vectors
Multivariate normal random values simulation on the simplex

Multivariate normal random values simulation on the simplex
Perturbation operation

Perturbation operation
Tuning of the bandwidth h of the kernel using the maximum likelihood cross validation

Tuning of the bandwidth h of the kernel using the maximum likelihood cross validation
Log-likelihood ratio test for a symmetric Dirichlet distribution

Log-likelihood ratio test for a symmetric Dirichlet distribution
Total variability

Total variability
Power operation

Power operation
Contour plot of the normal distribution in S^2

Contour plot of the normal distribution in \(S^2\)
Hotelling's multivariate version of the 1 sample t-test for Euclidean data

Hotelling's multivariate version of the 1 sample t-test for Euclidean data
Zero adjusted Dirichlet regression

Zero adjusted Dirichlet regression
Ternary diagram

Ternary diagram
Multivariate t random values simulation on the simplex

Multivariate t random values simulation on the simplex
Multivariate skew normal random values simulation on the simplex

Multivariate skew normal random values simulation on the simplex
Dirichlet random values simulation

Dirichlet random values simulation
Contour plot of the skew skew-normal distribution in S^2

Contour plot of the skew skew-normal distribution in \(S^2\)
Cross validation for the ridge regression

Cross validation for the ridge regression
Aithison's simple zero replacement strategy

Aithison's simple zero replacement strategy
Spatial median regression

Spatial median regression
Simulation of compositional data from the folded model

Simulation of compositional data from the folded model
Non linear least squares regression for compositional data

Non linear least squares regression for compositional data
Simulation of compositional data from Gaussian mixture models

Simulation of compositional data from Gaussian mixture models
Regularised discriminant analysis for Euclidean data

Regularised discriminant analysis for Euclidean data
Ridge regression

Ridge regression
Tuning the parameters of the regularised discriminant analysis

Tuning the parameters of the regularised discriminant analysis
Ridge regression plot

Ridge regression plot