Description Usage Arguments Value Examples
View source: R/summary.penPHcure.R
Produces a summary of a fitted penalized PH cure model, after selection of the tuning parameters, based on AIC or BIC criteria.
1 2 |
object |
an object of class |
crit.type |
a character string indicating the criterion used to select the tuning parameters, either |
... |
ellipsis to pass extra arguments. |
An object of class summary.penPHcure
, a list including the following elements:
|
the sample size (number of individuals). |
|
the proportion of censored individuals. |
|
the number of unique failure times. |
|
logical value: |
|
a character string indicating the type of penalty used, either |
|
a character string indicating the criterion used to select tuning parameters, either |
|
a list with elements named |
|
value of the minimized AIC/BIC criterion. |
|
a matrix where in the first column the estimated regression coefficients in the cure (incidence) component are provided. If the argument |
|
a matrix where in the first column the estimated regression coefficients in the survival (latency) component are provided. If the argument |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 | # Generate some data (for more details type ?penPHcure.simulate in your console)
set.seed(12) # For reproducibility
data <- penPHcure.simulate(N=250)
### Tune penalized cure model with SCAD penalties
# First define the grid of possible values for the tuning parameters.
pen.tuneGrid <- list(CURE = list(lambda = c(0.01,0.03,0.05,0.07,0.09),
a = 3.7),
SURV = list(lambda = c(0.01,0.03,0.05,0.07,0.09),
a = 3.7))
# Tune the penalty parameters.
tuneSCAD <- penPHcure(Surv(time = tstart,time2 = tstop,
event = status) ~ z.1 + z.2 + z.3 + z.4,
cureform = ~ x.1 + x.2 + x.3 + x.4,
data = data,pen.type = "SCAD",
pen.tuneGrid = pen.tuneGrid,
print.details = FALSE)
# Use the summary method to see the results
summary(tuneSCAD)
#
# ------------------------------------------------------
# +++ PH cure model with time-varying covariates +++
# +++ [ Variable selection ] +++
# ------------------------------------------------------
# Sample size: 250
# Censoring proportion: 0.5
# Number of unique event times: 125
# Tied failure times: FALSE
# Penalty type: SCAD
# Selection criterion: BIC
#
# ------------------------------------------------------
# +++ Tuning parameters +++
# ------------------------------------------------------
# Cure (incidence) --- lambda: 0.07
# a: 3.7
#
# Survival (latency) - lambda: 0.07
# a: 3.7
#
# BIC = -118.9359
#
# ------------------------------------------------------
# +++ Cure (incidence) +++
# +++ [ Coefficients of selected covariates ] +++
# ------------------------------------------------------
# Estimate
# (Intercept) 0.872374
# x.1 -0.958260
# x.3 0.685916
#
# ------------------------------------------------------
# +++ Survival (latency) +++
# +++ [ Coefficients of selected covariates ] +++
# ------------------------------------------------------
# Estimate
# z.1 0.991754
# z.3 -1.008180
# By default, the summary method for the penPHcure.object returns the selected
# variables based on the BIC criterion. For AIC, the user can set the
# argument crit.type equal to "AIC".
summary(tuneSCAD,crit.type = "AIC")
#
# ------------------------------------------------------
# +++ PH cure model with time-varying covariates +++
# +++ [ Variable selection ] +++
# ------------------------------------------------------
# Sample size: 250
# Censoring proportion: 0.5
# Number of unique event times: 125
# Tied failure times: FALSE
# Penalty type: SCAD
# Selection criterion: AIC
#
# ------------------------------------------------------
# +++ Tuning parameters +++
# ------------------------------------------------------
# Cure (incidence) --- lambda: 0.07
# a: 3.7
#
# Survival (latency) - lambda: 0.07
# a: 3.7
#
# AIC = -136.5432
#
# ------------------------------------------------------
# +++ Cure (incidence) +++
# +++ [ Coefficients of selected covariates ] +++
# ------------------------------------------------------
# Estimate
# (Intercept) 0.872374
# x.1 -0.958260
# x.3 0.685916
#
# ------------------------------------------------------
# +++ Survival (latency) +++
# +++ [ Coefficients of selected covariates ] +++
# ------------------------------------------------------
# Estimate
# z.1 0.991754
# z.3 -1.008180
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.