hatvis.dynamics.threshold_contagion#

hatvis.dynamics.threshold_contagion(H, beta=0.1, mu=0.05, theta=1.0, initial=0.05, n_steps=200, n_runs=10, random_state=None)[source]#

Discrete-time SIS contagion through hyperedges with a threshold.

In each step an infected vertex recovers with probability \(\mu\). A susceptible vertex \(i\) is exposed through every hyperedge \(e\ni i\) in which at least a fraction \(\theta\) of the other members are infected, and gets infected through it with probability \(\beta\) (de Arruda, Petri and Moreno 2020). With \(\theta=1\) a group transmits only if all others are infected, the rule of simplicial contagion (Iacopini et al. 2019); small \(\theta\) approaches pairwise spreading. initial is a fraction or a list of seed vertices. Returns the prevalence per step for every run.

Examples using hatvis.dynamics.threshold_contagion#

Threshold contagion through groups

Threshold contagion through groups