GithubHelp home page GithubHelp logo

epimodelcovid's Introduction

EpiModelCOVID

R-CMD-check

Modules for simulating SARS-CoV-2 transmission dynamics in different epidemiological settings, developed as an extension to our general network-based epidemic modeling platform, EpiModel.

EpiModel and EpiModelCOVID use the statistical framework of temporal exponential-family random graph models to fit and simulate models of dynamic contact networks. These statistical methods have been developed and implemented as open-source software, building on the extensive efforts of the Statnet research group to build software tools for the representation, analysis, and visualization of complex network data.

These packages combine these Statnet methods with an individual-based epidemic modeling engine to simulate SARS-Cov-2 transmission over networks, allowing for complex dependencies between the network, epidemiological, and demographic changes in the simulated populations. Readers new to these methods are recommended to consult our EpiModel resources, including our main methods paper Vignette describing the theory and implementation.

Installation

You can install EpiModelCOVID in R using remotes:

install.packages("EpiModel", dependencies = TRUE)
remotes::install_github("EpiModel/EpiModelCOVID")

Documentation on using this software package is forthcoming, although limited function documentation is provided within the package and available with the help(package = "EpiModelCOVID") command.

epimodelcovid's People

Contributors

adrienleguillou avatar chad-klumb avatar karina-d-wallrafen avatar kristinharrington avatar smjenness avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

epimodelcovid's Issues

del$dx referenced but not set

In mod_infection.R, infect_covid_corporate() and infect_covid_contacttrace() reference del$dx but that variable is never set (it does not exist).

# Case isolation with diagnosed or symptomatic infection
        if (at >= act.rate.dx.inter.time) {
          del$actRate[del$dx == 2] <- del$actRate[del$dx == 2] *
                                      act.rate.dx.inter.rr
        }

Error in update_cumlative_edgelist with ContactTrace branch

Running the test script for Kristin's EpiModelCOVID, I am encountering this error:

	A ERROR occured in module 'initialize.FUN' at step `Initialization Step` (1)
Error: Can't recycle input of size 4 to size 5.
Run `rlang::last_error()` to see where the error occurred.

within update_cumlative_edgelist specifically at the line:

  terminated_edges <- is.na(el_cuml[["current"]]) & is.na(el_cuml[["stop"]])
  if (any(terminated_edges)) {
    el_cuml[terminated_edges, ][["stop"]] <- at - 1
  }

Relevant files for reproducing the error:

  1. Script: https://github.com/EpiModel/COVID-ContactTrace/blob/updatePackages/R/03-epi-model-calib.R (use this updatePackages branch for now)
  2. Package: https://github.com/EpiModel/EpiModelCOVID/tree/ContactTrace

Looking for clarification on "discord_edgelist_covid_ship" function

Hello Sam,
This is Nisarg, part of the group adapting your cruise code for the hospital context. I was looking for your help to provide an insight into why "nw = 1" in line 221 of "mod-infection.R" , within the "discord_edgelist_covid_ship" function?

I noticed it did not seem to affect the outcome for the patient/ healthcare worker parameters (different parameter values for # of patients, health care workers & rooms compared to the cruise ship code) if I change it to "nw" or "nw=2" since the infection function is dependent on the network selected on the discordant edge.*

Thanks a lot for your help,
Nisarg

*edit: changing it to nw or nw=2 did have an effect on the cruise ship code. limiting the simulation output to both crew and passengers & only passengers respectively.

Mismatch in positional and unique IDs using get_partners() function

When filtering for eligible IDs for case investigation (e.g., status in c(a,ic,ip)), noticing that these are not always translating into the IDs being pulled by the get_partners() for the discordant edgelist.

For example: my idsEligCI are: 15, 657, 759, and 835. The index IDs in the discordant edgelist are 15, 659, 761, and 837. Seems like this is an issue with the positional versus unique IDs.

Relevant code for this issue: [https://github.com/EpiModel/EpiModelCOVID/blob/ContactTrace/R/mod-intervention.R]

Lines 27-28
idsEligCI <- which(active == 1 & status %in% c("a", "ic", "ip") & dxStatus == 2 & is.na(eligible.case))
Line 45
del_ct <- get_partners(dat, idsEligCI)

Global function definitions

In running R CMD check on ContactTrace, we are getting this as a NOTE:

   resim_nets_covid_contacttrace: no visible global function definition
     for ‘%n%<-resim_nets_covid_contacttrace: no visible global function definition
     for ‘%n%’
   resim_nets_covid_contacttrace: no visible global function definition
     foras.edgelistresim_nets_covid_corporate: no visible global function definition for
     ‘%n%<-resim_nets_covid_corporate: no visible global function definition for
     ‘%n%’
   resim_nets_covid_corporate: no visible global function definition foras.edgelistresim_nets_covid_ship: no visible global function definition for
     ‘%n%<-resim_nets_covid_ship: no visible global function definition for ‘%n%’
   resim_nets_covid_ship: no visible global function definition foras.edgelistUndefined global functions or variables:
     %n% %n%<- as.edgelist layer

Is this something we get also with EpiModelHIV? Is it an issue with imports?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.