
Plot transition matrices from run_multiple_get_results()
Source: R/plot_run_multiple.R
plot_multiple_transition.RdThis function takes the transition data frame from
run_multiple_get_results(), particularly, the transition component,
and visualizes it as a transition matrix using draw_mermaid_from_matrix().
Arguments
- x
A data frame in transition format, usually
run_multiple_get_results(model)$transition.- ...
Further arguments passed to
draw_mermaid_from_matrix().
Details
The function is automatically called when plotting an object of class
epiworld_multiple_save. It constructs a transition matrix from the
provided data frame, normalizes the rows to represent probabilities, and
then visualizes it using a mermaid diagram. The resulting plot illustrates
the transitions between different states in the model, with the thickness of
the arrows corresponding to the transition.