gce_riskscore: Normalized risk score and relative omega+ for new subjects

View source: R/scaling.R

gce_riskscoreR Documentation

Normalized risk score and relative omega+ for new subjects

Description

Computes the GCE risk score for new subjects using the covariate means/SDs and coefficients stored in a fitted model. This is a convenience wrapper around predict(), which offers the same quantities individually (type = "lp", "risk", "ratio", "share") and at arbitrary times. The score is the normalized (mean-centered) linear predictor, so exp(riskscore) is the subject's omega+ relative to the average subject in the fitting data (a value of 1 = same as average, 2 = twice the average omega+). For cause-specific (gcecox) models the absolute predicted omega+ and omega at the model's time t are also returned.

Usage

gce_riskscore(object, newdata)

Arguments

object

a "gcemod" object from gcecox, gcefg, or gcecif.

newdata

a data frame containing the covariates used to fit object (same column names and, for factors, levels seen in the fitting data).

Value

A data frame with riskscore and exp(riskscore) relative to the average subject: omegaplus_rel for omega+ models (with absolute omegaplus and omega at time t for cause-specific fits), or rho_rel for a gcecif fit.

See Also

gce_scaling

Examples

data(prostate)
fit <- gcecox(Surv(time, status) ~ age + psa + gleason, data = prostate, t = 10)
gce_riskscore(fit, newdata = prostate[1:5, ])

gcemod documentation built on Dec. 1, 2026, 1:06 a.m.