View source: R/plot_summary_print.R
plot.confint | R Documentation |
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 .
## S3 method for class 'confint'
plot(
x,
y = NULL,
y2 = NULL,
y3 = NULL,
which_par = x$which_pars[1],
conf = x$conf,
add_lines = TRUE,
legend = any(c(!is.null(y), !is.null(y2), !is.null(y3))),
legend_pos = "topleft",
...
)
x, y, y2, y3 |
objects of class |
which_par |
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 |
conf |
A numeric vector of values in (0, 100). If
|
add_lines |
A logical scalar. Whether or not to add horizontal lines
to the plot to identify the confidence limits. If there is only one
input |
legend |
A logical scalar or a character vector. If this is
supplied then a legend is added to the plot. If |
legend_pos |
The position of the legend (if required) specified using
the argument |
... |
Additional arguments passed to |
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.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.