mixnorm: The mixed normal distribution

Description Usage Arguments Author(s) Examples

Description

Density, distribution function, quantile function and random generation for the normal mixture distribution with means equal to 'mu' and standard deviations equal to 's'.

Usage

1
2
3
4

Arguments

x,q

vector of quantiles in dmixnorm and pmixnorm. In qmixnorm, 'x' is a vector of probabilities.

p

proportions of the mixture components.

prob

A vector of probabilities.

n

number of observations. If 'length(n) > 1', the length is taken to be the number required.

mean

vector of means

sd

vector of standard deviations

Author(s)

B. Wang bwang@southalabama.edu

Examples

1
2
3
4
5
6
7
p <- c(.4,.6)
mu <- c(1,4)
s <- c(2,3)
dmixnorm(c(0,1,2,20),p,mu,s)
pmixnorm(c(0,1,2,20),p,mu,s)
qmixnorm(c(0,1,.2,.20),p,mu,s)
rmixnorm(3,p,mu,s)

bda documentation built on May 29, 2017, 12:15 p.m.

Search within the bda package
Search all R packages, documentation and source code