# NOT RUN {
# Fit a Cox model
fit.ee <- coxphlb(Surv(a, y, delta) ~ x1 + x2, data = ExampleData1,
method = "EE")
# Check the Proportional Hazards Assumption
ptest1 <- coxphlb.phtest(fit.ee, data = ExampleData1, spec.p = 2,
seed.n = 1234)
print(ptest1) # display the results
# Run a Global Test
ptest2 <- coxphlb.phtest(fit.ee, data = ExampleData1, spec.p = NULL,
seed.n=1234)
print(ptest2) # display the results
# }
Run the code above in your browser using DataLab