graph_predictions: Graph a dataframe of model predictions.

graph_predictionsR Documentation

Graph a dataframe of model predictions.

Description

This function returns a ggplot

Usage

graph_predictions(
  predictions,
  geom = "bar",
  x = NULL,
  fill = NULL,
  facet = NULL,
  facet2 = NULL,
  colors = NULL
)

Arguments

predictions

A dataframe of model predictions. The y variable must be in the first column.

x

The variable to graph on the x axis.

fill

The (optional) variable to graph as a fill.

facet

The (optional) variable to graph as a facet

facet2

The (optional) variable to graph as a second facet (for 4-way interactions)

color

An optional vector of colors for bars or lines.

Value

A ggplot (bar or line graph).


michaelasher/asherR documentation built on July 5, 2023, 8:55 p.m.