For ipriorKernel
objects, the log-likelihood or deviance is calculated
at random parameter values by default. This is because it uses the
(random) initial values for the parameters from the EM algorithm. For
ipriorMod
objects, the default value is the last obtained set of
parameter values of the EM algorithm. If the model has converged, then this
should be the maximum likelihood (ML) value.
For both types of object, it is possible to supply a parameter value at which
to calculate the log-likelihood/deviance. This makes estimating an I-prior
model more flexible, by first loading the variables into an
ipriorKernel
object, and then using an optimiser such as
optim
. Any other optimiser that can implement bounded
constraints can be used. The only constraint requirement is on the parameter
psi
which has to be greater than zero (although setting the constraint
to a small number such as 1e-9
will avoid an ill conditioned
variance).
Direct maximisation of the log-likelihood of I-prior models can be unreliable
some times, but other times it could also lead to a better set of parameters
if the EM does not converge fully. Perhaps in the future, this package can
make use of both methods combined as standard.
As a side note, the ML estimate for the intercept of an I-prior model is the
mean of the responses y
, and therefore not included as a parameter of
the log-likelihood/deviance function.