R/curve_likelihood.R
as_curve_lik.RdTakes a grid of parameter values and the corresponding (profile)
log-likelihood and returns the same object structure as curve_lik(),
so all of concurve's plotting and tabling functions work on it.
This is the bridge between any likelihood-producing tool
(optim(), maxLik, bbmle, ProfileLikelihood,
hand-coded exact likelihoods) and concurve.
as_curve_lik(values, loglik, table = TRUE)A numeric vector of parameter values (the grid).
A numeric vector of log-likelihood values evaluated at
values. Any additive constant is allowed; the function
normalizes internally so the maximum relative likelihood is 1.
Indicates whether or not a table output with some relevant statistics should be generated. The default is TRUE and generates a table which is included in the list object.
A list with 2 items where the dataframe of values is in the
first object, and the table for the values in the second if
table = TRUE.