plot.classCoMiRe {CoMiRe} | R Documentation |
CoMiRe plot
Description
An S3 plot method for an object of classCoMiRe
class.
Usage
## S3 method for class 'classCoMiRe'
plot(
x,
y,
xobs,
mcmc,
J = 10,
H = 10,
a = NULL,
max.x = max(xobs),
bandwidth = 20,
x.grid = NULL,
xlim = c(0, max(xobs)),
ylim = c(0, 1),
xlab = "x",
alpha = 0.05,
risk = TRUE,
bmd = TRUE,
level,
oneevery = 20,
...
)
Arguments
x |
the output of |
y |
numeric vector for the response used in |
xobs |
numeric vector for the covariate relative to the dose of exposure used in |
mcmc |
a list giving the MCMC parameters. |
J |
parameter controlling the number of elements of the I-spline basis |
H |
total number of components in the mixture at |
a |
optional threshold of clinical interest for the response variable. |
max.x |
maximum value allowed for x. |
bandwidth |
the kernel bandwidth smoothing parameter for the |
x.grid |
optional numerical vector giving the actual values of the grid for x for plotting the additional risk function. If |
xlim , ylim |
numeric vectors of length 2, giving the x and y coordinates ranges for the plot. |
xlab |
the title of the x axis. |
alpha |
level of the credible bands, default 0.05 |
risk |
if |
bmd |
if |
level |
if |
oneevery |
integer number representing how many MCMC draws to plot in the posterior predictive check. It draws one sample every |
... |
additional arguments to be passed. |
Details
The output is a list of
ggplot2
plots containing the result of the betaplot
function and, if the threshold a
is provided, of
post.pred.check
, riskplot
, bmd.plot
.
Value
If a=NULL
returns only betaplot
otherwise, if risk=FALSE
and
bmd=FALSE
returns a list containing betaplot
(which is automatically plotted)
and post.pred.check
plot. Finally, if a
is provided, risk=TRUE
and bmd=TRUE
returns a list with betaplot
, post.pred.check
, riskplot
and bmd.plot
.
Author(s)
Antonio Canale, Arianna Falcioni