Learn R Programming

DStree (version 1.0)

dis.cost: Convert observed time points in Copenhagen Stroke Study data set

Description

This function rounds up the observed number of days in the cost data set (contained in R package pec) to full years.

Usage

dis.cost(cost)

Arguments

cost
data set

Value

A data frame that contains the same variables as the cost data frame in R package pec. The only difference between cost and the output of dis.cost are the units of the event times. In cost, event times are measured in days whereas dis.cost results in a data frame with event times measured in years.

References

Joergensen HS, Nakayama H, Reith J, Raaschou HO, and Olsen TS. Acute stroke with atrial fibrillation. The Copenhagen Stroke Study. Stroke, 27(10):1765-9, 1996.

Mogensen UB, Ishwaran H, and Gerds TA. Evaluating random forests for survival analysis using prediction error curves. Journal of Statistical Software, 50(11), 2012.

Examples

Run this code
data(cost)
d.cost <- dis.cost(cost)

Run the code above in your browser using DataLab