sim_n_mixture: Normal mixture sampling

View source: R/functions.R

sim_n_mixtureR Documentation

Normal mixture sampling

Description

produces samples from a mixture of n normal distributions.

Usage

sim_n_mixture(n, par, skeleton = NULL)

Arguments

n

The number of samples to generate

par

A list of parameter values. The first entry contains the

skeleton

An object which helps to relist the vector of parameters into the expected format.means of each component, the second the SDs, and the last contains the weights. An exponential link is applied to the SDs, and the probs_link function is used on the weights. probs_link is simply a variant of the qlogis link

Value

A vector of n generated normal-mixture samples.


calliste-fagard-jenkin/GAI documentation built on July 26, 2022, 11:20 a.m.