Plots transformation functions for objects produced by the bestNormalize package

# S3 method for bestNormalize
plot(
  x,
  inverse = FALSE,
  bounds = NULL,
  cols = NULL,
  methods = NULL,
  leg_loc = "top",
  ...
)

# S3 method for orderNorm
plot(x, inverse = FALSE, bounds = NULL, ...)

# S3 method for boxcox
plot(x, inverse = FALSE, bounds = NULL, ...)

# S3 method for yeojohnson
plot(x, inverse = FALSE, bounds = NULL, ...)

# S3 method for lambert
plot(x, inverse = FALSE, bounds = NULL, ...)

Arguments

x

a fitted transformation

inverse

if TRUE, plots the inverse transformation

bounds

a vector of bounds to plot for the transformation

cols

a vector of colors to use for the transforms (see details)

methods

a vector of transformations to plot

leg_loc

the location of the legend on the plot

...

further parameters to be passed to plot and lines

Details

The plots produced by the individual transformations are simply plots of the original values by the newly transformed values, with a line denoting where transformations would take place for new data.

For the bestNormalize object, this plots each of the possible transformations run by the original call to bestNormalize. The first argument in the "cols" parameter refers to the color of the chosen transformation.