Learn R Programming

icmstate (version 0.2.0)

graphfromIntervals: Construct Graph from censoring/truncation intervals

Description

Given intervals, construct a graph containing vertices representing these intervals and edges between the vertices if the intervals intersect. See Hudgens (2005).

Usage

graphfromIntervals(intervals)

Value

Returns an 'igraph' object containing the graph with vertices representing the intervals and edges between the vertices if the intervals intersect. The vertices will be named accordingly, starting with a 'T' when representing a truncation interval and 'C' when representing a censoring interval.

Arguments

intervals

A data.frame with 3 columns containing half-open intervals (left open, right closed) and an indicator whether the interval results from a censored transition or truncation: #'

L:

Left side of interval;

R:

Right side of interval;

cens:

Indicator whether interval resulted from censoring or truncation (1 = censoring, 0 = truncation);

Note that the truncation intervals need to be in the form (N, Inf] with N a numeric value.

References

Michael G. Hudgens, On Nonparametric Maximum Likelihood Estimation with Interval Censoring and Left Truncation, Journal of the Royal Statistical Society Series B: Statistical Methodology, Volume 67, Issue 4, September 2005, Pages 573-587, tools:::Rd_expr_doi("10.1111/j.1467-9868.2005.00516.x")