nri_est {psfmi} | R Documentation |
Calculation of Net Reclassification Index measures
Description
nri_est
Calculation of proportion of Reclassified persons and NRI for Cox
Regression Models
Usage
nri_est(data, p0, p1, time, status, t_risk, cutoff)
Arguments
data |
Data frame with relevant predictors |
p0 |
risk outcome probabilities for reference model. |
p1 |
risk outcome probabilities for new model. |
time |
Character vector. Name of time variable. |
status |
Character vector. Name of status variable. |
t_risk |
Follow-up value to calculate cases, controls. See details. |
cutoff |
A numerical vector that defines the outcome probability cutoff values. |
Details
Follow-up for which cases nd controls are determined. For censored cases before this follow-up
the expected risk of being a case is calculated by using the Kaplan-Meier value to calculate
the expected number of cases. These expected numbers are used to calculate the NRI proportions
but are not shown by function nricens
.
Value
An object from which the following objects can be extracted:
-
prop_up_case
proportion of cases reclassified upwards. -
prop_down_case
proportion of cases reclassified downwards. -
prop_up_ctr
proportion of controls reclassified upwards. -
prop_down_ctr
proportion of controls reclassified downwards. -
nri_plus
proportion reclassified for events. -
nri_min
proportion reclassified for nonevents. -
nri
net reclassification improvement.
Author(s)
Martijn Heymans, 2023
References
Cook NR, Ridker PM. Advances in measuring the effect of individual predictors of cardiovascular risk: the role of reclassification measures. Ann Intern Med. 2009;150(11):795-802.
Steyerberg EW, Pencina MJ. Reclassification calculations for persons with incomplete follow-up. Ann Intern Med. 2010;152(3):195-6; author reply 196-7.
Pencina MJ, D'Agostino RB Sr, Steyerberg EW. Extensions of net reclassification improvement calculations to measure usefulness of new biomarkers. Stat Med. 2011;30(1):11-21
Inoue E (2018). nricens: NRI for Risk Prediction Models with Time to Event and Binary Response Data. R package version 1.6, <https://CRAN.R-project.org/package=nricens>.
Examples
library(survival)
lbpmicox1 <- subset(psfmi::lbpmicox, Impnr==1) # extract dataset
fit_cox0 <-
coxph(Surv(Time, Status) ~ Duration + Pain, data=lbpmicox1, x=TRUE)
fit_cox1 <-
coxph(Surv(Time, Status) ~ Duration + Pain + Function + Radiation,
data=lbpmicox1, x=TRUE)
p0 <- risk_coxph(fit_cox0, t_risk=80)
p1 <- risk_coxph(fit_cox1, t_risk=80)
nri <- nri_est(data=lbpmicox1,
p0=p0,
p1=p1,
time = "Time",
status = "Status",
cutoff=0.45,
t_risk=80)