Draws an arrow from state x to state y if and only if on the equilibrium path there is a positive probability to directly transist from x to y.

eq_diagram(
  g,
  show.own.loop = FALSE,
  show.terminal.loop = FALSE,
  use.x = NULL,
  just.eq.chain = FALSE,
  x0 = g$sdf$x[1],
  hide.passive.edge = TRUE,
  label.fun = NULL,
  tooltip.fun = NULL,
  active.edge.color = "#000077",
  passive.edge.color = "#dddddd",
  add.passive.edge = TRUE,
  passive.edge.width = 1,
  return.dfs = FALSE,
  eq = g[["eq"]],
  font.size = 24,
  font = paste0(font.size, "px Arial black")
)

Arguments

g

The solved game object

show.own.loop

Shall a loop from a state to itself be drawn if there is a positive probability to stay in the state? (Default=FALSE)

show.terminal.loop

Only relevant if show.own.loop = TRUE. If still show.terminal.loop=FALSE omit loops in terminal state that don't transist to any other state.

use.x

optionally a vector of state ids that shall only be shown.

just.eq.chain

If TRUE only show states that can be reached with positive probability on the equilibrium path when starting from state x0.

x0

only relevant if just.eq.chain=TRUE. The ID of the x0 state. By default the first defined state.

label.fun

An optional function that takes the equilibrium object and game and returns a character vector that contains a label for each state.

tooltip.fun

Similar to label.fun but for the tooltip shown on a state.

return.dfs

if TRUE don't show diagram but only return the relevant edge and node data frames that can be used to call DiagrammeR::create_graph. Useful if you want to manually customize graphs further.

font.size

The font size