| plot.transitions | R Documentation |
Plotting the transitions of a diffusion
## S3 method for class 'diffusionTransitions'
plot(x, ..., compartments = NULL)
x |
A 'diffusionTransitions' table, as |
... |
Other arguments to be passed. |
compartments |
Optionally, the roles of the values,
as a named list such as |
plot.diffusionTransitions() draws the values of the attribute
as circles in a row,
and each transition as an arrow from one value to another,
labelled with its rate.
A transition to the next value in the row is straight,
a transition back is curved under the row,
and a transition that skips a value is curved over it.
A transition by contagion gets a dashed arrow from each value
that it comes from (its source),
labelled with how a node is exposed:
"threshold", "cascade", or "voter".
A rate that differs between nodes is labelled with its range, a rate from a node attribute with the name of the attribute, and a rate from a function with "f(x)".
plot.diffusionTransitions() returns a diagram of the values
and the transitions between them.
set.seed(1)
net <- manynet::play_diffusion(manynet::ison_adolescents, seeds = 1,
transmissibility = 0.5, onset = 0.6, recovery = 0.2, waning = 0.05)
plot(net$info$transitions)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.