Skip to contents

Combining mixture distributions of the same class to form a new mixture.

Usage

mixcombine(..., weight, rescale = TRUE)

Arguments

...

arbitrary number of mixtures with same distributional class. Each component with values of mixture weight and model parameters.

weight

relative weight for each component in new mixture distribution. The vector must be of the same length as input mixtures components. The default value gives equal weight to each component.

rescale

boolean value indicates if the weights are rescaled to sum to 1.

Value

A R-object with the new mixture distribution.

Details

Combines mixtures of the same class of random variable to form a new mixture distribution.

See also

robustify

Other mixdist: mixbeta(), mixgamma(), mixmvnorm(), mixnorm(), mixplot, mix

Examples

# beta with two informative components
bm <- mixbeta(inf=c(0.5, 10, 100), inf2=c(0.5, 30, 80))

# robustified with mixcombine, i.e. a 10% uninformative part added
unif <- mixbeta(rob=c(1,1,1))
mixcombine(bm, unif, weight=c(9, 1))
#> Univariate beta mixture
#> Mixture Components:
#>   inf    inf2   rob   
#> w   0.45   0.45   0.10
#> a  10.00  30.00   1.00
#> b 100.00  80.00   1.00