bd_calc_gauss_mix_pdf: Caculate the density of a possibly truncated Gaussian mixture

Description Usage Arguments Value

View source: R/bd_calc_gauss_mix_pdf.R

Description

bd_calc_gauss_mix_pdf calculates the probability density for a possibly truncated Gaussian mixture. The density, f', and rate, f'/f, can also be calculated by specifying the input type, which is 'density' by default, but can also be 'cumulative', 'derivative', or 'rate'. The parameter vector th has the ordering wk, muk, sigk, where wk, muk, and sigk are the weight, mean, and standard deviation of the k-th mixture. There are K total mixtures. The truncation boundaries ymin and ymax are optional.

Usage

1
bd_calc_gauss_mix_pdf(th, y, ymin = NA, ymax = NA, type = "density")

Arguments

th

A vector-like object that parameterizes the distribution

y

Vector of locations at which to calculate the density

type

(default density) An optional input specifying whether to calculate the density, cumulative distribution, derivative of the density, or rate

Value

The output vector with length G


MichaelHoltonPrice/BayDem documentation built on Sept. 12, 2019, 9:26 p.m.