View source: R/numericalDifferentiation.R
get_varying_h | R Documentation |
get_varying_h
adjusts differences for overly large degrees of freedom parameters
for finite difference approximation of the derivatives of the log-likelihood function. StMAR and
G-StMAR models are supported.
get_varying_h(p, M, params, model)
p |
a positive integer specifying the autoregressive order of the model. |
M |
|
params |
a real valued parameter vector specifying the model.
Symbol |
model |
is "GMAR", "StMAR", or "G-StMAR" model considered? In the G-StMAR model, the first |
This function is used for approximating gradient and Hessian of a StMAR or G-StMAR model. Large degrees of freedom parameters cause significant numerical error if too small differences are used.
Returns a vector with the same length as params
. For other parameters than degrees
of freedom parameters larger than 100, the differences will be 6e-6
. For the large degrees of
freedom parameters, the difference will be signif(df/1000, digits=2)
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.