paramtnormci_numeric {decisionSupport} | R Documentation |
Return parameters of truncated normal distribution based on a confidence interval.
Description
This function calculates the distribution parameters, i.e. mean
and sd
, of a
truncated normal distribution from an arbitrary confidence interval.
Usage
paramtnormci_numeric(
p,
ci,
lowerTrunc = -Inf,
upperTrunc = Inf,
relativeTolerance = 0.05,
rootMethod = "probability",
...
)
Arguments
p |
numeric 2-dimensional vector; probabilities of lower and upper bound of the
corresponding confidence interval.
|
ci |
numeric 2-dimensional vector; lower, i.e ci[[1]] , and upper bound, i.e
ci[[2]] , of the confidence interval.
|
lowerTrunc |
numeric ; lower truncation point of the distribution (>= -Inf ).
|
upperTrunc |
numeric ; upper truncation point of the distribution (<= Inf ).
|
relativeTolerance |
numeric ; the relative tolerance level of deviation of the
generated confidence interval from the specified interval. If this deviation is greater than
relativeTolerance a warning is given.
|
rootMethod |
character ; if ="probability" the equation defining the parameters mean and
sd is the difference between calculated and given probabilities of the confidence
interval; if ="quantile" the equation defining the parameters is the difference between
calculated and given upper and lower value of the confidence interval.
|
... |
Further parameters passed to nleqslv .
|
Details
For details of the truncated normal distribution see tnorm
.
#' @importFrom nleqslv nleqslv
Value
A list with elements mean
and sd
, i.e. the parameters of the underlying
normal distribution.
See Also
tnorm
, nleqslv
[Package
decisionSupport version 1.114
Index]