panel: Alternative panel functions for lattice plots

Description Usage Arguments Author(s) Examples

Description

Functions which can be used instead of the default functions in panel plots.

Usage

1
2
panel.hist(x, ...)
panel.cor(x, y, digits=2, prefix="", cex.cor)

Arguments

x, y

variables defining the contents of the panel.

digits

Number of decimals after dot with which correlations will be printed.

prefix

Prefix text for numbers.

cex.cor

Determines height of printed digits, may be missing.

...

graphical parameters can be supplied. see function definition for details.

Author(s)

??

Examples

1
2
3
4
n <- 1000; a <- rnorm(n,mean=1)
x <- matrix(c(a,a+2*log(runif(n)),a^2+0.2*rnorm(n,mean=1)),nrow = n)
pairs(x,lower.panel=panel.smooth, diag.panel=panel.hist,
upper.panel=panel.cor, labels = c("rnorm","rnorm+log(runif)","rnorm^2"))

Example output

Loading required package: lattice
Loading required package: grid

cwhmisc documentation built on May 1, 2019, 7:55 p.m.