ChA7-wtdlogrank: Weighted log-rank test

Description Usage Arguments Value Author(s) References See Also Examples

Description

Computes a two sample weighted log-rank statistic with events weighted according to one of the available weighting function choices

Usage

1
2
  wtdlogrank(formula = formula(data), data = parent.frame(), WtFun = c("FH", "SFH", "Ramp"),
  param = c(0, 0), sided = c(2, 1), subset, na.action, w = FALSE)

Arguments

formula

a formula of the form Surv(Time, Event) ~ arm where arm is a dichotomous variable with values 0 and 1.

data

a dataframe

WtFun

a selection from the available list: “FH” (Fleming-Harrington), “SFH” (stopped Fleming-Harrington) or “Ramp”. See param in the following line.

param

Weight function parameters. Length and interpretation depends upon the selected value of WtFun: If WtFun==FH then param is a length 2 vector specifying the power of the pooled (across arms) kaplan meier estimate and its complement. If WtFun==SFH then param is a length 3 vector with first two components as in the “FH” case, and third component the time (in the same units as the time to event) at which the “FH” weight function is capped off at its current value. If WtFun==SFH then param is of length 1 specifying the time (same units as time to event) at which events begin to get equal weight. The “Ramp” weight function is a linearly increasing deterministic weight function which is capped off at 1 at the user specified time.

sided

One or Two sided test? Set to 1 or 2

subset

Analysis can be applied to a subset of the dataframe based upon a logical expression in its variables

na.action

Method for handling NA values in the covariate, arm

w

currently no effect

Value

An object of class survtest containing components

pn

sample size

wttyp

internal representation of the WtFun argument

par

internal representation of the param argument

time

unique times of events accross all arms

nrisk

number at risk accross all arms at each event time

nrisk1

Number at risk in the experimental arm at each event time

nevent

Number of events accross all arms at each event time

nevent1

Number of events in the experimental arm at each event time

wt

Values of the weight function at each event time

pntimes

Number of event times

stat

The un-normalized weighted log-rank statistic, i.e. the summed weighted observed minus expected differences at each event time

var

Variance estimate for the above

UQt

Cumulative sum of increments in the sum resulting in stat above

varQt

Cumulative sum of increments in the sum resulting in var above

var1t

Cumulative sum of increments in the sum resulting in the variance of an unweighted version of the statistic

pu0

person units of follow-up time in the control arm

pu1

person units of follow-up time in the intervention arm

n0

events in the control arm

n1

events in the intervention arm

n

sample size, same as pn

call

the call that created the object

Author(s)

Grant Izmirlian <izmirlian@nih.gov>

References

Harrington, D. P. and Fleming, T. R. (1982). A class of rank test procedures for censored survival data. Biometrika 69, 553-566.

See Also

IntSurvDiff

Examples

1
2
3
  library(PwrGSD)
  data(lung)
  fit.wlr <- wtdlogrank(Surv(time, I(status==2))~I(sex==2), data=lung, WtFun="SFH", param=c(0,1,300))

PwrGSD documentation built on May 2, 2019, 4:54 p.m.