Learn R Programming

Compositional (version 1.0)

mix.compnorm: Gaussian mixture models for compositional data

Description

Gaussian mixture models for compositional data.

Usage

mix.compnorm(x, g, model, type = "alr")

Arguments

x
A matrix with the compositional data.
g
How many clusters to create.
model
The type of model to be used.
  1. "EII": All groups have the same diagonal covariance matrix, with the same variance for all variables.
  2. "VII": Different diagonal covariance matrices, with the same variance for all variables within each group.
type
Either the additive ("alr") or the isometric log-ratio transformation is to be used ("ilr").

Value

  • A list including:
  • muA matrix where each row corresponds to the mean vector of eahc cluster.
  • suAn array containing the covariance matrix of each cluster.
  • probThe estimated mixing probabilities.
  • estThe estimated cluster membership values.

Details

A log-ratio transformation is applied and then a Gaussian mixtued model is constructed.

References

Ryan P. Browne, Aisha ElSherbiny and Paul D. McNicholas (2015). R package mixture: Mixture Models for Clustering and Classification. Aitchison J. (1986). The statistical analysis of compositional data. Chapman & Hall.

See Also

bic.mixcompnorm, rmixcomp, mixnorm.contour

Examples

Run this code
x <- iris[, 1:4]
mod1 <- mix.compnorm(x, 3, model = "EII" )
mod2 <- mix.compnorm(x, 4, model = "VII")
mod1
mod2

Run the code above in your browser using DataLab