skewhypMeanVarMode | R Documentation |
Functions to calculate the mean, variance, skewness, kurtosis and mode of a specified skew hyperbolic t-distribution.
skewhypMean(mu = 0, delta = 1, beta = 1, nu = 1,
param = c(mu,delta,beta,nu))
skewhypVar(mu = 0, delta = 1, beta = 1, nu = 1,
param = c(mu,delta,beta,nu))
skewhypSkew(mu = 0, delta = 1, beta = 1, nu = 1,
param = c(mu,delta,beta,nu))
skewhypKurt(mu = 0, delta = 1, beta = 1, nu = 1,
param = c(mu,delta,beta,nu))
skewhypMode(mu = 0, delta = 1, beta = 1, nu = 1,
param = c(mu,delta,beta,nu),
tolerance = .Machine$double.eps ^ 0.5)
mu |
Location parameter |
delta |
Scale parameter |
beta |
Skewness parameter |
nu |
Shape parameter |
param |
Specifying the parameters as a vector of the form |
tolerance |
A difference smaller than this value is taken to be zero. |
Users may either specify the values of the parameters individually or
as a vector. If both forms are specified, then the values specified by
the vector param
will overwrite the other ones.In addition the
parameter values are examined by calling the function
skewhypCheckPars
to see if they are valid.
The moments are calculated as per formulae in Aas&Haff(2006) and the
mode is calculated by numerical optimisation of the density function
using optim
.
Note that the mean does not exist when \nu = 2
, the
variance does not exist for \nu \le 4
, the skewness
does not exist for \nu \le 6
, and the kurtosis does not
exist for \nu \le 8
.
skewhypMean
gives the mean of the skew hyperbolic
t-distribution, skewhypVar
the variance,
skewhypSkew
the skewness, skewhypKurt
the kurtosis and
skewhypMode
the mode.
David Scott d.scott@auckland.ac.nz, Fiona Grimson
Aas, K. and Haff, I. H. (2006). The Generalised Hyperbolic Skew Student's t-distribution, Journal of Financial Econometrics, 4, 275–309.
dskewhyp
, optim
,
skewhypCheckPars
, skewhypMom
param <- c(10,1,5,9)
skewhypMean(param = param)
skewhypVar(param = param)
skewhypSkew(param = param)
skewhypKurt(param = param)
skewhypMode(param = param)
range <- skewhypCalcRange(param = param)
curve(dskewhyp(x, param = param), range[1], range[2])
abline(v = skewhypMode(param = param), col = "red")
abline(v = skewhypMean(param = param), col = "blue")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.