Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

detectbound

Detect bounds for density function


Description

Manual detection of bounds of parameter of a density function/

Usage

detectbound(distname, vstart, obs, fix.arg=NULL, echo=FALSE)

Arguments

distname

A character string "name" naming a distribution for which the corresponding density function dname must be classically defined.

vstart

A named vector giving the initial values of parameters of the named distribution.

obs

A numeric vector for non censored data.

fix.arg

An optional named vector giving the values of fixed parameters of the named distribution. Default to NULL.

echo

A logical to show some traces.

Details

This function manually tests the following bounds : -1, 0, and 1.

Value

detectbound returns a 2-row matrix with the lower bounds in the first row and the upper bounds in the second row.

Author(s)

Christophe Dutang and Marie-Laure Delignette-Muller.

References

Delignette-Muller ML and Dutang C (2015), fitdistrplus: An R Package for Fitting Distributions. Journal of Statistical Software, 64(4), 1-34.

See Also

Examples

#case where the density returns a Not-an-Numeric value.
detectbound("exp", c(rate=3), 1:10)
detectbound("binom", c(size=3, prob=1/2), 1:10)
detectbound("nbinom", c(size=3, prob=1/2), 1:10)

fitdistrplus

Help to Fit of a Parametric Distribution to Non-Censored or Censored Data

v1.1-3
GPL (>= 2)
Authors
Marie-Laure Delignette-Muller [aut], Christophe Dutang [aut], Regis Pouillot [ctb], Jean-Baptiste Denis [ctb], Aurelie Siberchicot [aut, cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.