plot
method for class "confint".
Plots the (profile) loglikelihood for a parameter using the values
calculated by conf_intervals
.
Up to 4 different types of loglikelihood (see the argument type
to the function returned by adjust_loglik
)
may be superimposed on the same plot.
By default (add_lines = TRUE
) the confidence limits calculated
in conf_intervals
are indicated on the plot .
objects of class "confint"
, results of calls to
conf_intervals
for a common model. A (profile)
loglikelihood will be plotted for each object.
A scalar specifying the parameter for which the plot
is produced. Can be either a numeric scalar, specifying index of the
component of the full parameter vector, or a character scalar
parameter name. The former must be in x$which_pars
, the latter
must be in names(x$which_pars)
.
A numeric vector of values in (0, 100). If
add_lines = TRUE
then a horizontal line is added for each
value in conf
. If conf
is not supplied then the
value stored in x$conf
is used.
A logical scalar. Whether or not to add horizontal lines
to the plot to identify the confidence limits. If there is only one
input "confint"
object then the values of the confidence limits
will be added to the horizontal axis.
A logical scalar or a character vector. If this is
supplied then a legend is added to the plot. If legend
is a
character vector then it is used as the argument legend
to legend
. Otherwise, i.e. if
legend = TRUE
then the component type
of the input
object(s) x, y, y2, y3
are used.
The position of the legend (if required) specified using
the argument x
in legend
.
Additional arguments passed to matplot
or legend
. The arguments col
, lty
and lwd
will be used (in a consistent way) by both
matplot
and legend
.
Nothing is returned.
See the examples in conf_intervals
.
adjust_loglik
to adjust a user-supplied
loglikelihood function.
conf_intervals
for confidence intervals for
individual parameters.
conf_region
and plot.confreg
to
plot a confidence region for a pair of parameters.