View source: R/plot_functions.R
| plotRecruit | R Documentation |
A recruitment plot for a gsearly model.
plotRecruit(mod, xlim=NA, ylim=NA, xlab=NA, ylab=NA, title=NULL, col=NA,
lty=c(1,2), pch=3, las=1, wopcol=grey(0.9), intlab=NA, labpos=3,
legpos="topleft", tlag=c(0,0), pcol=1, ...)
mod |
A gsearly model from function |
xlim |
The |
ylim |
The |
xlab |
A label for the x axis; defaults to |
ylab |
A label for the y axis; defaults to |
title |
A main title for the plot; default |
col |
Plotting colors for the lines showing recruited numbers;
defaults to |
lty |
A vector of length 2 indicating the line types for the lines showing
numbers recruited and the interim analyses times; default |
pch |
Plotting character or symbol for points; default 3. |
las |
A numeric value which is one of either 0, 1, 2 or 3; the style of axis labels, 0: always parallel to the axis, 1: always horizontal (default), 2: always perpendicular to the axis, 3: always vertical. |
wopcol |
Color for the window of opportunity region, default
|
intlab |
A vector of labels for the interim analyses; defaults to t[1],
t[2], etc. Set to |
labpos |
Position of interim labels; default 3. |
legpos |
Legend position is one of |
tlag |
A vector of length 2, with positive values for time lags,
pre-recruitment and post-recruitment, over which to extend the plotted lines;
default |
pcol |
Color for points and interim lines; default 1. |
... |
Further arguments to plot function. |
A plot of the selected type or a list consisting of the plotted line and interim point data and bounds for the window of opportunity.
# For 90 percent power (pow), a call to gsearlyModel provides a feasible design
fp <- c(0.0000,0.0010,0.0250)
tn <- c(0.4800,0.7200,0.9750)
rctdesign <- gsearlyModel(rmodel="dilin", trecruit=36, s=3, tfu=c(3,6,12),
tinterims=c(16,31), pow=0.8,
cmodel="exponential", sd=20, rho=0.75, theta=8, fp=fp, tn=tn)
plotRecruit(rctdesign)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.