View source: R/hyperbCalcRange.R
hyperbCalcRange | R Documentation |
Given the parameter vector Theta of a hyperbolic distribution,
this function calculates the range outside of which the distribution
has negligible probability, or the density function is negligible, to
a specified tolerance. The parameterization used
is the (\pi,\zeta)
one (see
dhyperb
). To use another parameterization, use
hyperbChangePars
.
hyperbCalcRange(Theta, tol = 10^(-5), density = FALSE)
Theta |
Value of parameter vector specifying the hyperbolic distribution. |
tol |
Tolerance. |
density |
Logical. If |
The particular hyperbolic distribution being considered is specified
by the value of the parameter value Theta
.
If density = FALSE
, the function calculates
the effective range of the distribution, which is used in calculating
the distribution function and quantiles, and may be used in determining
the range when plotting the distribution. By effective range is meant that
the probability of an observation being greater than the upper end is
less than the specified tolerance tol
. Likewise for being smaller
than the lower end of the range.
If density = TRUE
, the function gives a range, outside of which
the density is less than the given tolerance. Useful for plotting the
density.
A two-component vector giving the lower and upper ends of the range.
David Scott d.scott@auckland.ac.nz, Jennifer Tso, Richard Trendall
Barndorff-Nielsen, O. and Blæsild, P (1983). Hyperbolic distributions. In Encyclopedia of Statistical Sciences, eds., Johnson, N. L., Kotz, S. and Read, C. B., Vol. 3, pp. 700–707. New York: Wiley.
dhyperb
, hyperbChangePars
par(mfrow = c(1,2))
Theta <- c(3,5,1,0)
hyperbRange <- hyperbCalcRange(Theta, tol = 10^(-3))
hyperbRange
curve(phyperb(x, Theta), hyperbRange[1], hyperbRange[2])
maxDens <- dhyperb(hyperbMode(Theta), Theta)
hyperbRange <- hyperbCalcRange(Theta, tol = 10^(-3)*maxDens, density = TRUE)
hyperbRange
curve(dhyperb(x, Theta), hyperbRange[1], hyperbRange[2])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.