Learn R Programming

accrued (version 1.2)

lagHistogram: Function to create a a summary histogram of completeness for each lag.

Description

This function creates a column of histograms, the $i$th histogram showing the distribution of completeness of data $i-1$ days after the encounter date.

Usage

lagHistogram(x, maxLagPlot=NULL, ...)

Arguments

x
Object of the accrued class containing data to be graphed.
maxLagPlot
Optional argument specifying the maximum accrual lag reprented in the plot.
...
Parameters to pass to plot.

Value

  • None.

Details

This function shows a complete summary of the completeness of the data by lag. The $i$th row of the column shows a histogram of the completion percent at $i-1$ days after the encounter date (so that the $x$-axis represents the completeness proportion in blocks of 0.1). Note that this function should only be used on count data.

See Also

plot.summary.accrued displays the mean completion rate for each lag.

Examples

Run this code
library(grid) 	
	data(accruedDataExample)			
	dat <- data.accrued(accruedDataExample)	
	lagHistogram(dat, maxLagPlot=7)

Run the code above in your browser using DataLab