plot_predict_var: Buids a variable profile plot with optional cutoffs at a...

Description Usage Arguments Value Examples

View source: R/model_training.R

Description

Buids a variable profile plot with optional cutoffs at a vector that differentiated categorical mappings

Usage

1
2
3
plot_predict_var(df, x, y = NA, xlabel = "default",
  ylabel = "default", cutoffs = NA, y_as_pct = FALSE,
  y_accuracy = 1, x_name_exact = TRUE)

Arguments

x

predictor variable

y

response variable

xlabel

what to call your predictor

ylabel

what to call your response

cutoffs

an optional vector of cut points where a numeric variable becomes a continuous variable

Value

ggplot2 object

Examples

1
2
plot_predict_var(mtcars, "wt", "mpg", "weight", "miles per gallon")
plot_predict_var(mtcars, "hp", "mpg", "horsepower", "miles per gallon", cutoffs = c(80, 135, 200))

dgarmat/dgfunctionpack documentation built on May 17, 2020, 9:58 p.m.