Learn R Programming

SimNPH (version 0.5.7)

analyse_piecewise_exponential: Create Analyse function for piecewise exponential model

Description

Create Analyse function for piecewise exponential model

Usage

analyse_piecewise_exponential(cuts, testing_only = FALSE)

Value

an analyse function that can be used in runSimulation

Arguments

cuts

interval boundaries for the piecewise exponential model

testing_only

if set to TRUE omits all statistics in the intervals and just returns the p value of the global test.

Details

If there's any time interval no patients ever enter, NA is returned for all time intervals. This behavior will likely change in future package versions.

Examples

Run this code
condition <- merge(
   assumptions_delayed_effect(),
   design_fixed_followup(),
   by=NULL
 ) |>
 head(1)
dat <- generate_delayed_effect(condition)
analyse_piecewise_exponential(cuts=c(90, 360))(condition, dat)

Run the code above in your browser using DataLab