cs2ic: Convert current status data into interval censored format

View source: R/user_utilities.R

cs2icR Documentation

Convert current status data into interval censored format

Description

Convert current status data into interval censored format

Usage

cs2ic(time, eventOccurred)

Arguments

time

Time of inspection

eventOccurred

Indicator if event has occurred. 0/FALSE implies event has not occurred by inspection time.

Details

Converts current status data to the interval censored format for usage in icenReg.

Examples


simData <- simCS_weib()
# Simulate current status data

head(cs2ic(simData$time, simData$event))
# Converting data to current status format

fit <- ic_par(cs2ic(time, event) ~ x1 + x2, data = simData)
# Can be used directly in formula


icenReg documentation built on May 29, 2024, 5:32 a.m.