findLoss: Find loss scores for a set of single-arm designs

View source: R/findLoss.R

findLossR Documentation

Find loss scores for a set of single-arm designs

Description

This function finds loss scores for single-arm designs, in particular, designs found using the function singlearmdesigns(). Weights w0 and w1 are chosen, and the loss for each design is found using the equation loss = w0\*ESS(0) + w1\*ESS(1) + (1-w0-w1)\*N

Usage

findLoss(main.output, w0, w1)

Arguments

main.output

Output from function singlearmDesigns().

w0

Choice of weight on ESS(0)

w1

Choice of weight on ESS(0)

Value

Output is a list identical to the output from function singlearmDesigns(), but with absolute and ranked loss scores added.

Author(s)

Martin Law, martin.law@mrc-bsu.cam.ac.uk

Examples

output <- singlearmDesign(nmin = 30,
 nmax = 30,
 C = 5,
 p0 = 0.1,
 p1 = 0.4,
 power = 0.8,
 alpha = 0.05)
 output.w.loss <- findLoss(main.output=output,
 w0=0.2,
 w1=0.3)

curtailment documentation built on Oct. 25, 2023, 5:06 p.m.