plot_coefs1: jtools::plot_coeffs personalization

plot_coefs1R Documentation

jtools::plot_coeffs personalization

Usage

plot_coefs1(
  ...,
  ci_level = 0.95,
  inner_ci_level = NULL,
  model.names = NULL,
  coefs = NULL,
  omit.coefs = c("(Intercept)", "Intercept"),
  colors = "CUD Bright",
  plot.distributions = FALSE,
  rescale.distributions = FALSE,
  exp = FALSE,
  point.shape = TRUE,
  point.size = 3,
  legend.title = "Model",
  groups = NULL,
  facet.rows = NULL,
  facet.cols = NULL,
  facet.label.pos = "top",
  color.class = colors,
  resp = NULL,
  dpar = NULL
)

Arguments

See ?jtools::plot_coefs

Details

This is a slight edition of the plot_coefs function in the package jtools. It only changes styling parameters.

Value

A ggplot object.

Note

If you encounter an error along the lines of not having the same number of attributes than elements and you are plotting categorical variables, remember to specify the variable + category name in the coefs argument. For example: you must specify c("Speciessetosa", "Speciesversicolor", "Speciesvirginica") (well, minus the reference one) and NOT only "Species".

This *feature* is present in the original function in the jtools package.

Author(s)

Valeria Rolle

Examples

mtcars$cyl <- as.character(mtcars$cyl)
mtcars$cat2 <- c(rep("primera", 16), rep("segunda", 16))

m1 <- glm(vs ~ carb + gear, data = mtcars, family = "binomial")
m2 <- glm(vs ~ cyl + drat + hp , data = mtcars, family = "binomial")
m3 <- glm(vs ~ cyl, data= mtcars, family = "binomial")

plot_coefs1(m3,m2)

ValeriaRolle/auxfun documentation built on June 29, 2023, 5:28 p.m.