eventProb {factorial2x2}R Documentation

Calculate event probabilities

Description

Calculates the event probabilities for each of the four factorial groups C, A, B, AB. The time unit is in years, but of course, any time unit could be used. Average event probabilities across various combinations of the groups are also calculated. The event times are assumed to be exponentially distributed. The censoring times are assumed to be uniformly distributed and indepedent of the event times.

Usage

eventProb(rateC, hrA, hrB, hrAB, mincens, maxcens)

Arguments

rateC

group C one year event rate

hrA

group A to group C hazard ratio

hrB

group B to group C hazard ratio

hrAB

group AB to group C hazard ratio

mincens

minimum censoring time

maxcens

maximum censoring time

Value

hazC

group C's exponential hazard rate

probC

event probability of the C group

probA

event probability of the A group

probB

event probability of the B group

probAB

event probability of the AB group

avgprob

average event probability across all factorial groups

probA_C

average event probablity of the A and C groups

probAB_C

average event probablity of the AB and C groups

Examples

# Corresponds to scenario 5 of Table 2 from Leifer, Troendle, et al. (2019).
rateC <- 0.0445
hrA <- 0.80
hrB <- 0.80
hrAB <- 0.72
mincens <- 4.0
maxcens <- 8.4
eventProb(rateC, hrA, hrB, hrAB, mincens, maxcens)
# hazC
# [1] 0.04552052

# probC
# [1] 0.2446365

# probA
# [1] 0.201254

# probB
# [1] 0.201254

# probAB
# [1] 0.1831806

# avgprob
# [1] 0.2075813

# probAB_C
# [1] 0.2139086

[Package factorial2x2 version 0.2.0 Index]