posterior samples of model parameters.
a matrix or data.frame of size m \times p (m: sample size, p: dimension of the parameters).
prior.func
a prior function. An argument should be a vector of parameter values and
a return value should be the log prior density for those parameter values.
alp
a real value between 0 and 1. α takes a value between 0 and 1, which is the nearest neighbor bandwidth
with the kth smallest distance d where k = lfloor n α
floor and d(x, x_{i}) = | x - x_{i} |
with the sample size n
method
an optimization method to be used in maximizing the approximation to the unnormalized log-likelihood.
Options from optim are Nelder-Mead, BFGS, CG, L-BFGS-B, and SANN.
lower, upper
bounds on the variables for the L-BFGS-B method in optim.
control
a list of control parameters. See control options for optim.
use.locfit
logical. If TRUE, locfit is used to compute a local likelihood density estimate. If FALSE, a code from the mcll package is used. locfit is typically faster but sometimes fails for high-dimensional parameter spaces.
con.manual
a list. An optimization method for finding the polynomial coefficients, lower and upper bounds on the variables for the L-BFGS-B method, and a list of control parameters when use.locfit = FALSE. See control options for optim.
Details
Nested maximizations in Step 2 in the Monte Carlo local likelihood estimation.
It makes use of the R package locfit and the R function optim.
The posterior samples should be on the real line (e.g., variance parameters should be on the log-scale).
The prior distributions (provided as a form of prior.func) should be the same as those used for obtaining the posterior
samples of the model parameters.
For details, see Section 2 in Jeon et al. (2012).
Value
mcll_est returns a list of the following components,
par
parameter estimates on the original scale.
value
value of the function corresponding to par. This is an unnormalized log-likelihood from the MCLL algorithm.
One can use this to compute the Bayes factor. For details, see Appendix of Jeon et al. (2012).
counts
a two-element integer vector giving the number of calls to function and gradient, respectively.
convergence
an integer code. 0 indicates successful completion.
For possible error codes, see the document for optim.
message
a character string giving any additional information returned by optim, or NULL.
Author(s)
Minjeong Jeon <jeon.117@osu.edu>
References
Jeon, M., Kaufman, C., and Rabe-Hesketh, S. (2014). Monte Carlo local likelihood
for approximate MLE of complex models. Under revision.
Loader, C. (2012). locfit: Local regression, likelihood, and density estimation. Downloadable from
http://cran.r-project.org/web/packages/locfit/index.html.