plot.sa_des_adaptive: Plot the second stage sample sizes of two-stage adaptive...

Description Usage Arguments Details Value See Also Examples

View source: R/plot.sa_des_adaptive.R

Description

Plots the second stage sample sizes of two-stage adaptive single-arm trial designs determined using des_adaptive(). The values of n2(sn1 )) are plotted.

Usage

1
2
## S3 method for class 'sa_des_adaptive'
plot(x, ..., output = F)

Arguments

x

An object of class "sa_des_adaptive", as returned by des_adaptive().

...

Additional objects of class "sa_des_adaptive". These will be grouped in to a list named "add_des".

output

A logical variable indicating whether the outputs described below should be returned.

Details

Support is available to simultaneously plot the second stage sample sizes of multiple two-stage adaptive single-arm clinical trial designs for a single binary primary endpoint.

Value

If output = TRUE, a list containing the following elements is returned

See Also

des_adaptive, opchar_adaptive, and their associated plot family of functions.

Examples

1
2
3
4
5
6
7
8
# Find the optimal adaptive two-stage design for the default parameters
des    <- des_adaptive()
# Plot the stopping boundaries
plot(des)
# Find the optimal adaptive two-stage design for a 10% type-I error rate
des_10 <- des_adaptive(alpha = 0.1)
# Plot the second stage sample sizes for both designs
plot(des, des_10)

mjg211/singlearm documentation built on May 8, 2021, 3:17 a.m.