Description Usage Arguments Details Value References Examples
View source: R/optimal.cutpoint.R
This function finds the first optimal cutpoint for the time-varying regression effects based on the maximized score statistics and calculates p-value based on a formula from Davies (1987) and O'Quigley and Pessione (1991). This is for depth 1 only.
1 2 | optimal.cutpoint(survtime, survstatus, x, method = "breslow", acpf = 10,
iter.max = 20, eps = 1e-06)
|
survtime |
survival time/ follow up time of subjects |
survstatus |
survival status of subjects. 0 for censored and 1 for an event |
x |
a data frame of covariates. In case of a single covariate, use |
method |
argument for coxph function. Default is 'breslow'. See |
acpf |
The search for the optimal cutpoint starts from the ((acpf/2)+1)th event until the (k - (acpf/2))th event, where k is the total number of events. Default is 10. |
iter.max |
the maximum number of iteration in coxph; default is 20. See |
eps |
argument for coxph function; default is 0.000001. See |
optimal.cutpoint
takes in survival time, survival status, and covariates to find the first optimal cutpoint.
Currently, data need to be arranged in descending order of time and with no missing.
optimal.cutpoint
returns the following information:
breakpt |
optimal cutpoint |
scoretest |
Maximum score associated with the optimal cut point |
summary |
3 output from |
pvalue |
p-value to test the existance of a change point against none |
Davies, R. (1987). Hypothesis Testing when a Nuisance Parameter is Present Only Under the Alternatives. Biometrika, 74(1), 33-43.
O'Quigley, J., and Pessione, F. (1991). The Problem of a Covariate-Time Qualitative Interaction in a Survival Study. Biometrics, 47(1), 101-115.
1 2 3 4 5 6 |
Loading required package: survival
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.