gehan.test: Gehan generalization the Wilcoxon two-sample test

View source: R/gehan.test.r

gehan.testR Documentation

Gehan generalization the Wilcoxon two-sample test

Description

Generalization of the Wilcoxon rank sum which allows for censored data.

Usage

 gehan.test(time, event, trt) 

Arguments

time

Time of event or of censoring

event

Indicator variable representing a event occur or not (time is censored)

trt

Variable indicating treatment group.

Value

statistic

Value of the test statistic

p.value

p-value

Author(s)

John Kloke

References

Higgins (2004), Introduction to Modern Nonparametric Statistics, Pacific Grove, CA:Brooks/Cole–Thomson Learning

Examples

n<-76
y<-rexp(n)
event<-rbinom(n,1,0.7) # about 30%  censored
trt<-sample(c(0,1),n,replace=TRUE)
gehan.test(y,event,trt)

npsm documentation built on Nov. 15, 2023, 1:08 a.m.