Learn R Programming

isoph (version 1.1.3)

isoph: Fit Isotonic Proportional Hazards Model

Description

Nonparametric estimation of an isotonic covariate effect for proportional hazards model.

Usage

isoph(formula, trt, data, shape, K, maxdec, maxiter, eps)

Arguments

formula

a formula object: a response ~ a univariate covariate. The response must be survival outcome unsing the Surv function in the survival package.

trt

Treatment group. It must be coded by 0 or 1. This argument is optional.

data

data.frame or list that includes variables named in the formula argument.

shape

direction of the covariate effect on the hazard function, "increasing" or "decreasing".

K

an anchor constraint is imposed at K (default is 0).

maxdec

maximum number of decisimal for output (default is 2).

maxiter

maximum number of iteration (default is 10^4).

eps

stopping convergence criteria (default is 10^-3).

Details

The isoph function allows to analyze isotonic proportional hazards model, defined as $$ \lambda(t|z,trt)=\lambda0(t)exp(\psi(z)+\beta trt), $$ where \( \lambda0 \) is a baseline hazard function, \( \psi \) is an isotonic function, \(z\) is a univariate variable, \(\beta\) is a regression parameter and \(trt\) is a binary treatment group variable. One point has to be fixed with \( \psi(K)=0 \), where \( K \) is an anchor point. A direction of \( \psi \) is defined as monotone increasing or monotone decreasing in \(Z\) prior to data analysis. Pseudo iterative convex minorant algorithm is used.

References

Yunro Chung, Anastasia Ivanova, Michael M. Hudgens, Jason P. Fine, Partial likelihood estimation of isotonic proportional hazards models, Biometrika. In print.

Examples

Run this code
# NOT RUN {
###
# 1. time-independent covariate with monotone increasing effect
###
# 1.1. create a test data set 1
test1=list(
  time=  c(2, 5, 1, 7, 9, 5, 3, 6, 8, 9, 7, 4, 5, 2, 8),
  status=c(0, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1),
  z=     c(2, 1, 1, 3, 5, 6, 7, 9, 3, 0, 2, 7, 3, 9, 4)
)

# 1.2. Fit isotonic proportional hazards model
res1 = isoph(Surv(time, status)~z, data=test1, shape="increasing")

# 1.3. print result
print(res1)
plot(res1)

###
# 2. time-independent covariate with monotone increasing effect and treatment group
###
# 2.1. create a test data set 1
test2=list(
  time=  c(2, 5, 1, 7, 9, 5, 3, 6, 8, 9, 7, 4, 5, 2, 8),
  status=c(0, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 1),
  z=     c(2, 1, 1, 3, 5, 6, 7, 9, 3, 0, 2, 7, 3, 9, 4),
  trt=   c(1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 0)
)

# 2.2. Fit isotonic proportional hazards model
res2 = isoph(Surv(time, status)~z, trt=trt, data=test2, shape="increasing")

# 2.3. print result
print(res2)
plot(res2)
# }

Run the code above in your browser using DataLab