Skip to contents

This function can compute different types of OC probabilities

Usage

OC_Curve_Diff_Rules2(
  rules,
  theta_pick,
  tpp_tb,
  previous_full_rules,
  plot_params = list(contour_vec = c(0.25, 0.5, 0.75))
)

Arguments

rules

a data.frame with gocut, nogocut, n in this ORDER to specify the settings of Operating Characteristics(OC). gocut: Declare Go if #resp >= gocut nogocut: Declare Nogo if #rest <= nogocut n: sample size when making the go/nogo decision

theta_pick

vector of underlying ORR that you want to show in the figure

tpp_tb

tibble(data.frame) storing TPP values of theta, it must have tpp_tb$theta and tpp_tb$tpp. tpp_tb$theta will be used to match against theta_pick

previous_full_rules

a data.frame specifies all previous stage-wise rules.

plot_params

list of plotting parameters, currently, it supports contour_vec: a vector storing the contour lines

Value

A list containing:

  1. Detailed OC data

  2. A list of ggplot object of OC curves.

  3. Plot parameters