Learn R Programming

curtailment (version 0.2.6)

plotByWeight: plotByWeight

Description

This function shows the omni-admissible design -- the design realisation with the lowest loss score -- from a subset of admissible designs. The input is an object created by singlearmDesign.

Usage

plotByWeight(main.output, split.by.cohort.size = TRUE)

Value

An object of class ggplot if either the chosen designs have only one unique cohort size or if split.by.cohort.size is FALSE. Otherwise, a list containing multiple ggplot objects is returned. The objects show which design has the lowest loss score, at each possible set of weights (w0, w1). Each design is characterised using the format {r/N, thetaF/thetaE}.

Arguments

main.output

Object created by the function(s) listed above.

split.by.cohort.size

Logical. If TRUE, creates separate plots for each cohort size/block size/ number of stages. Defaults to TRUE.

Examples

Run this code
designs <- singlearmDesign(nmin=30, nmax=30, C=5, p0=0.1, p1=0.4, power=0.8, alpha = 0.05)
plotByWeight(designs)

Run the code above in your browser using DataLab