Learn R Programming

bayesMCClust (version 1.0)

calcAllocations: Computes Group Sizes, Group Membership and Individual Posterior Classification Probabilities

Description

Computes (estimates) group sizes, group membership and individual posterior classification probabilities based on the outcome of a specificed MCMC run of either mcClust, mcClustExtended, dmClust or dmClustExtended as well as MNLAuxMix.

Usage

calcAllocationsMCC(outList, thin = 1, maxi = 50, 
                   M0 = outList$Mcmc$M0, plotPathsForEta = TRUE)
calcAllocationsMCCExt(outList, thin = 1, maxi = 50, 
                   M0 = outList$Mcmc$M0)
calcAllocationsDMC(outList, thin = 1, maxi = 50, 
                   M0 = outList$Mcmc$M0, plotPathsForEta = TRUE)
calcAllocationsDMCExt(outList, thin = 1, maxi = 50, 
                   M0 = outList$Mcmc$M0)
calcAllocationsMNL(outList, thin = 1, maxi = 50, 
                   M0 = outList$Mcmc$M0)

Arguments

Value

A list containing:estGroupSizeA vector of dimension $H$ containing the posterior mean of group sizes. For MCC and DMC without MNL extension estGroupSize contains the mixing proportions/weights $\hat{\eta}$. In these cases each thin-th MCMC draw beginning at M0 (after burn-in) is used for calculation. For MCC and DMC with MNL extension and MNLAuxMix the group sizes are calculated based on the individual posterior classification probabilities which are calculated using the last maxi draws of each thin-th MCMC draw.classA vector of length $N$ containing the group membership, which is determined for each individual according to the maximum individual posterior classification probability.classProbsA matrix with dimension $N \times H$ containing the individual posterior classification probabilities which are calculated using the last maxi draws of each thin-th MCMC draw.

Details

The last maxi MCMC draws of each thin-th draw are taken for calculations, except for mixing proportions $\eta$ (which are part of MCC and DMC without MNL extension) where all thin-th draws beginning at M0 are used.

References

Sylvia Fruehwirth-Schnatter, Christoph Pamminger, Andrea Weber and Rudolf Winter-Ebmer, (2011), "Labor market entry and earnings dynamics: Bayesian inference using mixtures-of-experts Markov chain clustering". Journal of Applied Econometrics. DOI: 10.1002/jae.1249 http://onlinelibrary.wiley.com/doi/10.1002/jae.1249/abstract Christoph Pamminger and Sylvia Fruehwirth-Schnatter, (2010), "Model-based Clustering of Categorical Time Series". Bayesian Analysis, Vol. 5, No. 2, pp. 345-368. DOI: 10.1214/10-BA606 http://ba.stat.cmu.edu/journal/2010/vol05/issue02/pamminger.pdf

See Also

mcClust, dmClust, mcClustExtended, dmClustExtended, MNLAuxMix

Examples

Run this code
# please run the examples in mcClust, dmClust, mcClustExtended, 
# dmClustExtended, MNLAuxMix

Run the code above in your browser using DataLab