paired.plotBA: Bland-Altman plot

Description Usage Arguments Value Author(s) References See Also Examples

Description

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

Usage

1
2
paired.plotBA(df, condition1, condition2, groups = NULL, 
facet = TRUE, ...)

Arguments

df

a data.frame.

condition1

name of the variable corresponding to the first sample.

condition2

name of the variable corresponding to the first sample.

groups

name of the variable corresponding to the groups (optional).

facet

faceting or grouping strategy for plotting?

...

arguments to be passed to methods

Value

a graphical object of class ggplot.

Author(s)

Stephane CHAMPELY

References

See Also

tmd

Examples

1
2
3
4
5
data(PrisonStress)
paired.plotBA(PrisonStress,"PSSbefore","PSSafter")

# Extending the resulting ggplot object by faceting
paired.plotBA(PrisonStress,"PSSbefore","PSSafter")+facet_grid(~Group)

Example output

Loading required package: MASS
Loading required package: gld
Loading required package: mvtnorm
Loading required package: lattice
Loading required package: ggplot2

Attaching package: 'PairedData'

The following object is masked from 'package:base':

    summary

PairedData documentation built on May 1, 2019, 6:49 p.m.