e_plot_table_prop: Calculate proportions and plot factor variable by up to two...

View source: R/e_plot_table_prop.R

e_plot_table_propR Documentation

Calculate proportions and plot factor variable by up to two other factor variables

Description

Calculate proportions and plot factor variable by up to two other factor variables

Usage

e_plot_table_prop(dat_plot = NULL, var_names = NULL, sw_print = FALSE)

Arguments

dat_plot

data to plot

var_names

proportions are calculated for first variable, by up to two other variables (row facets, then column facets), c("y", "a", "b")

sw_print

T/F whether to print table and display plot

Value

     a list including a table and ggplot object

Examples

e_plot_table_prop(
    dat_plot  = dat_mtcars_e
  , var_names = c("vs")
  )
e_plot_table_prop(
    dat_plot  = dat_mtcars_e
  , var_names = c("vs", "am")
  )
e_plot_table_prop(
    dat_plot  = dat_mtcars_e
  , var_names = c("vs", "am", "gear")
  )

erikerhardt/erikmisc documentation built on April 17, 2025, 10:48 a.m.