fPCStage1: Determine stage 1 rejections for adaptive multiple testing

View source: R/adaptive_two_stage.R

fPCStage1R Documentation

Determine stage 1 rejections for adaptive multiple testing

Description

Determine the elementary hypotheses rejected at stage 1 and the intersection hypotheses retained for stage 2.

Usage

fPCStage1(stg1_loc_p, alpha1)

Arguments

stg1_loc_p

A list returned by fPCStagewise, containing the stage 1 intersection hypotheses and local p-values.

alpha1

Stage 1 significance level.

Value

A list containing:

  • stg1_elemhyp_r_idx: The 1-based indices of elementary hypotheses rejected in stage 1.

  • stg1_inthyp_nr_idx: The 1-based indices of intersection hypotheses not rejected in stage 1.

  • inthyp: The indicator matrix of those non-rejected intersection hypotheses.

Author(s)

Kaifeng Lu, kaifenglu@gmail.com

References

Cyrus Mehta, Ajoy Mukhopadhyay, and Martin Posch. Graph Based, Adaptive, Multiarm, Multiple Endpoint, Two-Stage Designs. Statistics in Medicine. 2025.

Examples

wgtmat <- fwgtmat(c(0.5, 0.5, 0, 0),
                  matrix(c(0, 0.5, 0.5, 0,
                           0.5, 0, 0, 0.5,
                           0, 1, 0, 0,
                           1, 0, 0, 0),
                         nrow = 4, byrow = TRUE))
family <- matrix(c(1, 1, 0, 0,
                   0, 0, 1, 1),
                 nrow = 2, byrow = TRUE)
corr <- matrix(c(1, 0.5, NA, NA,
                 0.5, 1, NA, NA,
                 NA, NA, 1, 0.5,
                 NA, NA, 0.5, 1),
               nrow = 4, byrow = TRUE)
stage1_local_pvalues <- fPCStagewise(
  stg2_p = c(0.00045, 0.0952, 0.0225, 0.1104),
  wgtmat = wgtmat, family = family, corr = corr,
  stg1_inthyp_nr = 1:15, stg2_elemhyp = 1:4,
  stg2_wgtmat = wgtmat, test = "dunnett",
  nthreads = 1)
fPCStage1(stg1_loc_p = stage1_local_pvalues,
          alpha1 = errorSpent(0.5, 0.025, "sfOF"))


lrstat documentation built on Aug. 25, 2026, 5:07 p.m.