The Censored Normal Distribution
Density, distribution function, quantile function, and random generation for the left and/or right censored normal distribution.
dcnorm(x, mean = 0, sd = 1, left = -Inf, right = Inf, log = FALSE)
pcnorm(q, mean = 0, sd = 1, left = -Inf, right = Inf, lower.tail = TRUE, log.p = FALSE)
rcnorm(n, mean = 0, sd = 1, left = -Inf, right = Inf)
qcnorm(p, mean = 0, sd = 1, left = -Inf, right = Inf, lower.tail = TRUE, log.p = FALSE)
- x, q
vector of quantiles.
vector of probabilities.
number of observations. If
length(n) > 1, the length is taken to be the number required.
vector of means.
vector of standard deviations.
left censoring point.
right censoring point.
- log, log.p
logical; if TRUE, probabilities p are given as log(p).
logical; if TRUE (default), probabilities are P[X <= x] otherwise, P[X > x].
sd are not specified they assume the default values
right have the defaults
The censored normal distribution has density \(f(x)\):
|\(\Phi((left - \mu)/\sigma)\)||if \(x \le left\)|
|\(1 - \Phi((right - \mu)/\sigma)\)||if \(x \ge right\)|
where \(\Phi\) and \(\phi\) are the cumulative distribution function and probability density function of the standard normal distribution respectively, \(\mu\) is the mean of the distribution, and \(\sigma\) the standard deviation.
dcnorm gives the density,
pcnorm gives the distribution
qcnorm gives the quantile function, and
generates random deviates.