explore: Data statistics for an age-dependent model
Description
Data statistics that are important for fitting an age-dependent multi-state model. Basic summaries and additional information on the age distribution in the data
Usage
explore(data = NULL, id = NULL, state = NULL, age = NULL,
digits = 3, HIST = TRUE, hist.col = c("green","red",
"blue"), INFO = FALSE)
Arguments
data
Data frame with variables id, state, and age
id
Identifier. Specify if data is not provided
state
State variable. Specify if data is not provided
age
Age or transformed age. Specify if data is not provided
digits
Number of digits in the output
HIST
TRUE for histograms of the age distribution. FALSE otherwise
hist.col
Colours for the three histograms of the age distribution
INFO
TRUE for returning a list which links id with time intervals between the subsequent records. FALSE otherwise
Value
intervals
Data frame with variables interval.length and corresponding id (when INFO = TRUE)