- Network models can now use predefined scenarios with the
use_scenariofunction. See the Working with Model Parameters vignette for details.
trim_netestfunction has been added to reduce
netestobject sizes in common use cases.
networkLiteclass now supports some additional functionalities.
- Duration = 1 time step models in
tergmLite = FALSEnow use
tergmsimulation to produce a
networkDynamicclass object, similar to the duration > 1 time step case.
netdxnow supports heterogeneous dissolution model diagnostics. See the example in
type = "duration","dissolution"for homogeneous ("edges-only") dissolution models.
- Network model parameters can now be supplied to
data.frame. See the Working with Model Parameters vignette for details.
- A new term
fuzzynodematchwas added, to support modeling of more generalized notions of homophily.
- Network models can now be checkpointed to automate saving, recovering, and restarting simulations after interruption, as might occur with large-scale simulation jobs on high-performance computing (HPC) systems. See
- EpiModel's custom terms
absdiffnodemixare now usable again (due to enabling symbol search).
- The correct formula is now used in
sim_nets_t1when initializing the network with the non-nested edges dissolution approximation approach in
- References to
networkclass internals have been removed from
net.utils.Rto make the code function properly with
update_dissolutionnow correctly handles duration 1 models.
get_cumulative_edgelistsnow throw informative errors when the
networkrefers to non-existing networks.
get_cumulative_edgelists_dfwill throw errors as well as they call those functions internally.
updater.netmodule was removed as an optional module but its functionalities are now the default behavior for all network models (built-in and custom).
- The parameters
control.netrespectively were renamed
.control.updater.list. The leading dot indicates that these are built-in EpiModel elements not to be confused with the user-defined ones.
- Dissolution models using the
nodefactorterm have been deprecated.
stergmcontrols have been deprecated in favor of
- Formula-style simulations are used consistently for both
tergmsimulation, requiring control arguments of class
ndtvis added to "Suggests" (again) and
plot.transmatnow accepts the
- Systematic review and improvement of documentation across the package.
netdxnow have default control arguments following R's default argument mechanism.
- Simulation names are now attached to
netsimobject fields produced via the
- Imputed durational corrections for onset-censored edges are now sampled from a geometric distribution rather than simply using the mean of that distribution.
- Improved optional module
updater.netallowing it to update the model controls as well as the parameters. See the vignette, "Working with model parameters."
- General updates to the names and content of the included vignettes.
- Fix dissolution model statistics calculations for
netsimin the case with a model with an "end horizon" (when the network is not resimulated at the end of the time series).
- Fix duplicate printing issues across
- Fix use of
all.equalin unit tests as requested by CRAN.
- Change defaults of newly introduced cumulative edgelist functionality to not store it (improves speed).
posit_idsto return unchanged
- We have changed the names of arguments from the function
get_partnersnewly introduced in EpiModel v2.2.0:
max.ageis renamed to
truncatefor consistency with the other cumulative edgelist functions;
only.active.nodesto clarify that this argument subsets by nodes and not by partnerships.
- Developed a general approach to tracking and querying historical and contacts, called a cumulative edgelist. This may be used, for example, to query the recent but non-current contacts of newly infected nodes. See the vignette, "Working with network objects".
create_dat_objecthelper function was added to standardize the creation of the core
- The current timestep within
netsimsimulations is now stored in the
datobject and accessible with
get_current_timestep. This eliminates the need to explicitly pass
atas a function argument, although that is still allowed.
- Addition of the
get_param_setfunction that extracts from a
netsimobject the set of parameters used by each simulation. See the help page:
- Developed a mechanism to store nodal attribute history over the course of a
netsimsimulation. See the vignette, "Working with attributes and summary statistics."
- Developed an optional module to define prevalence statistics (also called "epi stats") as functions to be passed to the model as control settings before each
netsimsimulation. This allows users to avoid updating the
prevalence.netmodule. See the vignette, "Working with attributes and summary statistics."
- Developed an optional module allowing the update of the model parameters over timesteps within
netsimsimulations (i.e., time-varying parameters). See the vignette, "Working with model parameters."
- Improved the random parameterization programming interface to allow correlation between parameters in each simulation (e.g., the ability to pass in a multivariate parameter set for each simulation). See the vignette, "Working with model parameters."
- When calling
netsimobject, the arguments in the ellipsis (
...) are now correctly passed to the
- When trying to use the built-in
netsimwill now output a more explicit error if the values used are not only
- Fixed the names of the target formation statistics in
edapprox == FALSEthat were causing the plotting functions to misbehave.
- Simplification of the
set_transmatfunction removing the assumption that
dat$stats$transmatwas to exist only if
at != 2(thanks to @thednainus).
- More consistent formation and dissolution statistics print between
- Removed duplication in the printing of the parameters when a parameter was defined both as fixed and as random.
- When using custom
type == NULL, some built-in modules no longer stop because they required
typeto be a string.
- Fixed issue with
- Fixed problem with unique ID counter not saved by
saveout.net, resulting in the unique ids to start a 1 again when restarting a model from a previous simulation.
- The new home for EpiModel on Github is: https://github.com/EpiModel/EpiModel. It was previously located on the
statnetorganization on Github.
- Summary network statistics for
netsimclass objects (epidemic simulations) are now available when
tergmLiteis used. Previously these network statistics were only available when
tergmLite = FALSEbut updates to the
tergmLitemade this possible. These network stats are output with
- Developed a general storage and printing mechanism for the recently developed random parameterization interface. See the help page
- Cleaned up the handling of the initial network simulation in
initialize.net, so that the user-facing code in that function is more readable, and the more complex code is put in
- Addressed errors in handling cross-sectional network simulations embedded within a dynamic epidemic model (e.g., contacts that last the length of one time step, specified by
duration = 1in
- Added new
update_paramsfunction to add new parameters to an existing list of network parameters specified in
param.net. This aids in workflows that distinguish fixed parameters versus varying parameters that may change across scenarios or simulations.
- Added new general interface for random parameters in network models that allows randomly drawing a parameter value from a specified statistical distribution, where the distribution may either be a sampling of discrete values or a factory function for any of R's random statistical distribution functions. See help file for
- Implemented a standardized approach with helper functions for setting core attributes (those nodal attributes which should be present in any workflows) in network models. This functionality is specified with
append_core_attrfunction in the initialization and arrival modules in any extension models. This includes a standardized implementation of persistent, unique IDs as an attribute that remains constant for nodes even with open population models.
- With the use of a standardized core attribute framework that now correctly handles unique IDs in all models, now the transmission matrix objects output from any network model work consistently and correctly for both closed population and open population models.
- For DCM models with
dt < 1, fix
NAoutput for any
- Reduce complexity of some unit tests that were stochastically generating errors due to ERGM MCMC estimation problems.
- Fix problem with temporally extended status variables in network models (i.e., tracking of disease status history across time steps) by simplifying the general approach that works across built-in and extension model types.
- Reimplemented the handling of relational age diagnostics in
netdx, with updated numerical summaries in
print.netdxand visuals in
plot.netdx. Because relational ages are left-censored for any edges that existed at time zero, this led to a misleading diagnostic that ages were lower than the targeted durations. Imputation of a start time for those edges was added, with the option in
plot.netdxto visualize with imputed start times (default = TRUE) or not.
- More consistent approach to trimming unneeded environmental data from ERGM objects implemented with
statnet.common::trim_env(), used in
- Reimplemented the
netest"edges dissolution approximation" for efficient estimation of a temporal ERGM via a cross-sectional ERGM estimation with adjustment of formation model coefficients (see
netesthelp page). This new approach further reduces bias in the approximation method, plus now allows for non-nested dissolution models (i.e., dissolution formula does not need to be a subset of the formation formula).
- Implemented an error catching approach for
netsimso that epidemic modules
with errors or warnings are clearly identified in the console.
- Allow saving the transmission matrix with
independently of using tergmLite methods (previously use of tergmLite did not
allow for saving these data).
- Added an
infstatparameter to the internal
in the infection module, to allow for arbitrary specification of which disease
statuses are considered infectious for the purpose of dyad discordance.
- Added ability to vary node size in
type = 'network'with
- Fix issue for
plot.netdxwhen plot legend set to
print.netsimthat does not error when displaying new epidemic
modules for extension models.
- Use appropriate tergmLite resimulation methods for
netsimfor networks with
duration of 1 (i.e., one-time contacts handled with cross-sectional ERGMs).
- Further minor edits/updates to EpiModel 2.0 migration documentation (posted on
- This release introduces a major update to the EpiModel package infrastructure and application programming interface for both built-in models (primarily used for teaching purposes) and extension models (primarily used for research purposes). The major substantive changes are summarized in a EpiModel 1.x to EpiModel 2.0 migration guide on our primary website: https://epimodel.org/.