eda_bipow: Ladder of powers transformation on bivariate data with...

View source: R/eda_bipow.R

eda_bipowR Documentation

Ladder of powers transformation on bivariate data with three-point summary plot

Description

Re-expresses a vector on the ladder of powers. Requires eda_3pt() function.

Usage

eda_bipow(dat, x, y, p = c(-1, 0, 0.5, 1, 2), tukey = TRUE, ...)

Arguments

dat

Data frame

x

Column name assigned the x axis

y

Column name assigned the y axis

p

Vector of powers

tukey

If set to TRUE, then adopt Tukey's power transformation. If FALSE, adopt Box-Cox transformation.

...

Other parameters passed to the graphics::plot function.

Details

Generates a matrix of scatter plots and boxplots of various re-expressions of both x and y values. The 3-point summary and associated half-slopes are also plotted (this function makes use of the eda_3pt function). The values are re-expressed using either the Tukey power transformation (default) or the Box-Cox transformation (see eda_re for more information on these transformation techniques). Axes labels are omitted to reduce plot clutter.

Value

No return value

References

  • Tukey, John W. 1977. Exploratory Data Analysis. Addison-Wesley.

Examples


data(cars)
# Example 1
eda_bipow(dat = cars, x = speed, y = dist)
# Custom powers
eda_bipow(dat = cars, x = speed, y = dist, p = c(-1, -0.5, 0, 0.5, 1))
# Adopt box-cox transformation
eda_bipow(dat = cars, x = speed, y = dist, tukey = FALSE, p = c(-1, -0.5, 0, 0.5, 1))


mgimond/tukeyedar documentation built on March 19, 2024, 8:44 a.m.