Learn R Programming

sp23design (version 0.9-1)

computeDGivenXi: Given the estimates of the \(\pi\) and \(\theta\), compute \(d\).

Description

This function computes \(d\) via $$d(\pi,\xi)=\{ \pi_0 a + (1-\pi_0)\} - \{\pi_1 abc + (1-\pi_1)b \} $$

Usage

computeDGivenXi(piVec, xiVec)

Arguments

piVec

The two-element vector of \((\pi_0, \pi_1)\)

xiVec

The three-element vector of \((a=e^\alpha, b=e^\beta, c=e^\gamma)\)

Value

The computed value of \(d\), a scalar

Details

This is an approximation to the hazard ratio

References

Lai, Tze Leung and Lavori, Philip W. and Shih, Mei-Chiung. Sequential Design of Phase II-III Cancer Trials, Statistics in Medicine, Volume 31, issue 18, p.1944-1960, 2012.