plotChronograph: Plot a chronograph

View source: R/Chronograph.R

plotChronographR Documentation

Plot a chronograph

Description

Creates a plot showing the observed and expected nunber of outcomes for each month in the 3 years before and after initiation of the exposure, as well as the IC. The full process is described in Noren et al.

Usage

plotChronograph(data, exposureId, outcomeId, title = NULL, fileName = NULL)

Arguments

data

Data as generated using the getChronographData function.

exposureId

The unique ID identifying the exposure to plot.

outcomeId

The unique ID identifying the outcome to plot.

title

The title to show above the plot.

fileName

Name of the file where the plot should be saved, for example 'plot.png'. See the function ggsave in the ggplot2 package for supported file formats.

References

Noren GN, Hopstadius J, Bate A, Star K, Edwards R, Temporal pattern discovery in longitudinal electronic patient records, Data Mining and Knowledge Discovery, May 2010, Volume 20, Issue 3, pp 361-387.


OHDSI/IcTemporalPatternDiscovery documentation built on Sept. 16, 2022, 1:11 p.m.