exp_events {npsurvSS}R Documentation

Expected number of events

Description

Given one or two treatment arms, calculate the expected number of events d at time \tau.

Usage

exp_events(arm0 = NA, arm1 = NA, tau = NA)

Arguments

arm0

object of class 'arm'.

arm1

object of class 'arm'.

tau

vector of times. Defaults to total study duration.

Value

expected number of events.

See Also

exp_duration for calculating time to achieve expected events d, create_arm and create_arm_lachin for creating an object of class 'arm'.

Examples

arm0 <- create_arm(size=120, accr_time=6, surv_scale=0.05, loss_scale=0.005, follow_time=12)
arm1 <- create_arm(size=120, accr_time=6, surv_scale=0.03, loss_scale=0.005, follow_time=12)
exp_events(arm0)
exp_events(arm0, arm1)
exp_events(arm0, tau=c(10,NA))
exp_events(arm0, arm1, tau=c(10,NA))

[Package npsurvSS version 1.1.0 Index]