linear.trend.test: Test for linear trend (in log-hazard ratios)

Description Usage Arguments Value References Examples

Description

Performs a test for linear trend of log-hazard ratios in stratified survival data.

Usage

1
2
linear.trend.test(time, status, exposure, strata,
  scores = seq_along(length(levels(strata))))

Arguments

time

a numeric vector of survival times.

status

a numeric vector of censoring indicators, with 0 = censored and 1 = dead.

exposure

a factor vector with two levels indicating exposure. The first level is assumed to be the exposed condition.

strata

a factor vector with at least two levels indicating strata.

score

group score.

Value

An object of class "htest" with title, test statistic, and p-value.

References

Newman (2001), page 221.

Examples

1
2
3
4
5
6
## Example 10.14
with(breast.survival, linear.trend.test(time, status, receptor.level, stage)) 

## Using specified scores
with(breast.survival, linear.trend.test(time, status, receptor.level, stage,
                                        scores = c(1,2,6))) 

clayford/bme documentation built on May 13, 2019, 7:37 p.m.