Plots a trial design plan.
# S3 method for TrialDesignPlan
plot(x, y, main = NA_character_,
xlab = NA_character_, ylab = NA_character_,
type = ifelse(x$.design$kMax == 1, 5, 1), palette = "Set1",
theta = seq(-1, 1, 0.01), plotPointsEnabled = NA,
legendPosition = NA_integer_, showSource = FALSE, ...)The trial design plan, obtained from
getSampleSizeMeans,
getSampleSizeRates,
getSampleSizeSurvival,
getPowerMeans,
getPowerRates or
getPowerSurvival.
Not available for this kind of plot (is only defined to be compatible to the generic plot function).
The main title.
The x-axis label.
The y-axis label.
The plot type (default = 1). The following plot types are available:
1: creates a 'Boundaries' plot
2: creates a 'Boundaries Effect Scale' plot
3: creates a 'Boundaries p Values Scale' plot
4: creates a 'Type One Error Spending' plot
5: creates a 'Sample Size' or 'Overall Power and Early Stopping' plot
6: creates a 'Number of Events' or 'Sample Size' plot
7: creates an 'Overall Power' plot
8: creates an 'Overall Early Stopping' plot
9: creates an 'Expected Number of Events' or 'Expected Sample Size' plot
10: creates a 'Study Duration' plot
11: creates an 'Expected Number of Subjects' plot
12: creates an 'Analysis Times' plot
13: creates a 'Cumulative Distribution Function' plot
14: creates a 'Survival Function' plot
The palette, default is "Set1".
A vector of theta values.
If TRUE, additional points will be plotted.
The position of the legend.
By default (NA_integer_) the algorithm tries to find a suitable position.
Choose one of the following values to specify the position manually:
-1: no legend will be shown
NA: the algorithm tries to find a suitable position
0: legend position outside plot
1: legend position left top
2: legend position left center
3: legend position left bottom
4: legend position right top
5: legend position right center
6: legend position right bottom
If TRUE, the parameter names of the object will
be printed which were used to create the plot; that may be, e.g.,
useful to check the values or to create own plots with plot.
Optional ggplot2 arguments.
Generic function to plot all kinds of trial design plans.