Computes the probability density function of a finite mixture of normal distributions at a given point or vector of points.
dnorm_mixture(x, mu, sigma, pi)A numeric vector containing the values of the mixture density evaluated
at x.
Numeric vector of points at which the density is evaluated.
Numeric vector of component means.
Numeric vector of component standard deviations.
Numeric vector of mixing proportions. Must have the same length
as mu and sigma, and sum to 1.