epiNet
class models require a
complex series of statistical modeling, random simulations,
and bookkeeping. After the network model is estimated,
disease is simulated upon networks using the
epiNet.simTrans
function. Within this
function are a series of steps to initialize the
simulation, and then randomly set new infections,
recoveries, and vital dynamics on the network.Addressing novel research questions will likely require
modifying or expanding the existing functionality of
epiNet.simTrans
code. Our software design goal has
been to "modularize" the internal processes within
epiNet.simTrans
in order to present the procedures
of these network models clearly for easy editing and
supplementation.
A set of related procedures are known as modules. In this
help page, we present a brief overview of the module
functions in the order in which they are used within
epiNet.simTrans
to help guide users on the "big
picture" for their own code expansion. Note that these
functions are not shown on the main help page index since
they are not called directly by the end-user. Review the
help pages for these functions for further details.
init.status
: sets which nodes are initially
infected, either through thei.num
ori.ids
parameters.init.inf.time
: sets the
time of infection for those nodes which were infected ininit.status
.init.pids
:
establishes persistent ID numbers for bipartite network
simulations with vital dynamics.infection
: simulates
disease transmission given an edgelist of serodisdant
partnerships by calculating the relevant transmission and
act rates for each nodal pair, and then updated the nodal
attributes and summary statistics.discord.edgelist
: determines from the
network object which edges are active, and then the
subset of active edges which are comprised of a
serodiscordant (one node susceptible and one node
infected) nodal pairs.recovery
:
simulates recovery from infection either to a lifelong
immune state (for SIR models) or back to the susceptible
state (for SIS models), as a function of the recovery
rate specified in therec.rate
parameter.deaths.sus
:
randomly simulates death for susceptible status nodes
given the death rate specified in theds.rate
parameter. This involves deactivating susceptible nodes.deaths.inf
: randomly simulates death
for infected status nodes given the death rate specified
in thedi.rate
parameter. This involves
deactivating infected nodes.deaths.rec
: randomly simulates death for
recovered status nodes given the death rate specified in
thedr.rate
parameter. This involves deactivating
recovered nodes.births
: randomly
simulates new births into the network given the current
population size and the birth rate specified in theb.rate
parameter. This involves adding new nodes
into the network.