Create a function suitable for computation of numeric moments. This function is
used internally by compute_moment when the user chooses nn, and is
unlikely to need to be called by a user directly.
make_numeric_moment_function(nn, j, quad = NULL, centre = 0, shift = NULL, ...)get_shift(gg)
Object of class aghqmoment, see make_moment_function
Order of moment to be computed, see nn argument of compute_moment.
Numeric, positive integer, index of parameter vector to compute the numeric moment for.
Optional, object of class aghq, only used if shift is not NULL.
Numeric scalar, added to shift to ensure that central moments
remain far from zero.
Numeric scalar, amount by which to shift theta. The function that this
outputs is g(theta) = (theta)^nn + shift, and shift is returned with the
object so that it may later be subtracted. Default of NULL chooses this value
internally.
Not used.
Object of class aghqmoment. Returns the shift applied to
the moment function. Returns 0 if no shift applied.