RPSFT: A function to do RPSFT

Description Usage Arguments Examples

Description

This function applies RPSFT method

Usage

1
2
RPSFT(x, psimat = matrix(ncol = 1, data = seq(from = -3, to = 3, by = 0.1)),
  Grho = 0, twopass = TRUE)

Arguments

x

An extended survival object created using SurvExt()

psimat

A matrix of values to try in grid search

Grho

Defines the test used in the grid search (0 = logrank, 1 = wilcoxon)

twopass

Defines if two searches are performed (wide then fine)

Examples

1
2
3
4
5
6
7
sim.df <- simStudy()
x <- SurvExt(Surv(os.t, os.e) ~ I(x.trt==1),
   Exposure = ifelse(x.trt == 1, os.t, ifelse(x.switch == 1, os.t - t.switch, 0)),
   AdminCensTime = t.censor,
   data = sim.df)
plot(x)
RPSFT(x)

iain-t-bennett/SwitchPack documentation built on May 16, 2019, 11:07 a.m.