Learn R Programming

PairedData (version 0.9.1)

plotBA: Bland-Altman plot

Description

Produce a Bland-Altman plot for paired data, including a confidence region for the mean of the differences.

Usage

## S3 method for class 'paired':
plotBA(object,groups=NULL,facet=TRUE,...)

Arguments

object
an object of class paired.
groups
factor corresponding to groups (optional).
facet
faceting or grouping strategy for plotting?
...
arguments to be passed to methods

Value

  • a graphical object of class ggplot.

References

  • J.M. Bland and D.G. Altman. Measuring agreement in method comparison studies. Statistical Methods in Medical Research, 8, 135-160, 1999.
  • D.M. Meek. Two macros for producing graphs to assess agreement between two variables. In Proceedings of Midwest SAS Users Group Annual Meeting, October 2007.

See Also

tmd

Examples

Run this code
data(PrisonStress)
with(PrisonStress,plotBA(paired(PSSbefore,PSSafter)))
with(PrisonStress,plotBA(paired(PSSbefore,PSSafter),
groups=Group))
with(PrisonStress,plotBA(paired(PSSbefore,PSSafter),
groups=Group,facet=FALSE))

Run the code above in your browser using DataLab