Infections and Progressions

Overview Structs

Overview Functions

Structs

GEMS.DiseaseProgressionType
DiseaseProgression

A struct to represent the disease progression of an infectious disease.

Fields

  • exposure::Int16: Exposure (infection) tick of the disease.
  • infectiousness_onset::Int16: Tick when the individual becomes infectious.
  • symptom_onset::Int16: Tick when the individual develops symptoms.
  • severeness_onset::Int16: Tick when the individual develops severe symptoms.
  • critical_onset::Int16: Tick when the individual develops critical symptoms.
  • critical_offset::Int16: Tick when the individual's critical symptoms subside.
  • severeness_offset::Int16: Tick when the individual's severe symptoms subside.
  • recovery::Int16: Tick when the individual recovers from the disease.

Constraints

  • exposure must be non-negative.
  • infectiousness_onset must be at least one tick after exposure.
  • symptom_onset is optional but must be at least one tick after exposure if set.
  • severeness_onset is optional, but if set, requires symptom_onset, cannot be prior to symptom_onset, and requires severeness_offset.
  • severeness_offset is optional, but if set, requires severeness_onset and cannot be prior to severeness_onset.
  • critical_onset is optional, but if set, requires severeness_onset, cannot be prior to severeness_onset, and requires critical_offset.
  • critical_offset is optional, but if set, requires critical_onset and cannot be prior to critical_onset.
  • recovery must be set, at least one tick after exposure, and cannot be prior to symptom_onset, severeness_offset, or critical_offset if set.

Examples

The following example represents a mild symptomatic progression. An individual get infected at time 23, becomes infectious at 25, develops symptoms at 26, recovers at 31, and does not die.

julia> DiseaseProgression(exposure = 23, infectiousness_onset = 25, symptom_onset = 26, recovery  = 31)

Output:

DiseaseProgression(
  tick | event
    23 | exposure
    25 | infectiousness_onset
    26 | symptom_onset
    31 | recovery
)

Functions

Missing docstring.

Missing docstring for can_infect. Check Documenter's build log for details.

GEMS.exposureMethod
exposure(dp::DiseaseProgression)

Returns the exposure (infection) tick of the disease progression dp.

GEMS.infect!Function
infect!(infectee::Individual,
    tick::Int16,
    pathogen::Pathogen,
    sim::Union{Simulation, Nothing},
    rng::Xoshiro,
    infecter_id::Int32,
    setting_id::Int32 ,
    lon::Float32,
    lat::Float32,
    setting_type::Char,
    ags::Int32,
    source_infection_id::Int32)

Infect infectee with the specified pathogen and calculate time to infectiousness and time to recovery. Optional arguments infecter_id. setting_id, and setting_type can be passed for logging. It's not required to calulate the infection. The infection can only be logged, if Simulation object is passed (as this object holds the logger).

Parameters

  • infectee::Individual: Individual to infect
  • tick::Int16: Infection tick
  • pathogen::Pathogen: Pathogen to infect the individual with
  • sim::Union{Simulation, Nothing} = Simulation object (used to get logger)
  • rng::Xoshiro: RNG to use for stochastic parts
  • infecter_id::Int32: Infecting individual
  • setting_id::Int32: ID of setting this infection happens in
  • lon::Float32: Longitude of the infection infection location (setting)
  • lat::Float32: Latitude of the infection infection location (setting)
  • setting_type::Char: Setting type as char (e.g. "h" for Household)
  • ags::Int32*: Amtlicher Gemeindeschlüssel (community identification number) of the region this infection happened in as Integer value
  • source_infection_id::Int32: Current infection ID of the infecting individual

Returns

  • Int32: New infection ID, or DEFAULT_INFECTION_ID if infectee is already actively infected with pathogen.
infect!(infectee::Individual, sim::Simulation)

Infect infectee with the pathogen of the simulation at the current tick of the simulation. Mainly a convenience wrapper around infect! with less parameters. Used for example in test cases.

GEMS.infectiousness_onsetMethod
infectiousness_onset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp becomes infectious.

GEMS.is_asymptomaticMethod
is_asymptomatic(dp::DiseaseProgression, t::Int16)
isasymptomatic(dp::DiseaseProgression, t::Int16)
asymptomatic(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp is asymptomatic at tick t, otherwise false. Asymptomatic means the individual is infected, does currently not have symptoms and will not develop symptoms in the future.

GEMS.is_criticalMethod
is_critical(dp::DiseaseProgression, t::Int16)
iscritical(dp::DiseaseProgression, t::Int16)
critical(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp has critical symptoms at tick t, otherwise false.

GEMS.is_infectedMethod
is_infected(dp::DiseaseProgression, t::Int16)
isinfected(dp::DiseaseProgression, t::Int16)
infected(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp is infected at tick t, otherwise false.

GEMS.is_infectiousMethod
is_infectious(dp::DiseaseProgression, t::Int16)
isinfectious(dp::DiseaseProgression, t::Int16)
infectious(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp is infectious at tick t, otherwise false.

GEMS.is_mildMethod
is_mild(dp::DiseaseProgression, t::Int16)
ismild(dp::DiseaseProgression, t::Int16)
mild(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp has mild symptoms at tick t, otherwise false. A mild case is defined as symptomatic but not severe.

GEMS.is_presymptomaticMethod
is_presymptomatic(dp::DiseaseProgression, t::Int16)
ispresymptomatic(dp::DiseaseProgression, t::Int16)
presymptomatic(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp is presymptomatic at tick t, otherwise false. Presymptomatic means the individual is infected but has not yet developed symptoms (but will in the future).

GEMS.is_recoveredMethod
is_recovered(dp::DiseaseProgression, t::Int16)
isrecovered(dp::DiseaseProgression, t::Int16)
recovered(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp has recovered before tick t, otherwise false.

GEMS.is_severeMethod
is_severe(dp::DiseaseProgression, t::Int16)
issevere(dp::DiseaseProgression, t::Int16)
severe(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp has severe symptoms at tick t, otherwise false.

GEMS.is_symptomaticMethod
is_symptomatic(dp::DiseaseProgression, t::Int16)
issymptomatic(dp::DiseaseProgression, t::Int16)
symptomatic(dp::DiseaseProgression, t::Int16)

Returns true if the individual with disease progression dp is symptomatic at tick t, otherwise false.

GEMS.critical_onsetMethod
critical_onset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp develops critical symptoms. If the individual will not develop critical symptoms, this will return -1.

GEMS.critical_offsetMethod
critical_offset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp's critical symptoms subside. If the individual never has critical symptoms, this will return -1.

GEMS.recoveryMethod
recovery(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp recovers from the disease.

GEMS.severeness_onsetMethod
severeness_onset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp develops severe symptoms. If the individual will not develop severe symptoms, this will return -1.

GEMS.severeness_offsetMethod
severeness_offset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp's severeness is reduced (i.e., moves from severe to mild symptoms). If the individual never has severe symptoms, this will return -1.

Missing docstring.

Missing docstring for spread_infection!(::Setting, ::Simulation, ::Pathogen). Check Documenter's build log for details.

GEMS.symptom_onsetMethod
symptom_onset(dp::DiseaseProgression)

Returns the tick when the individual with disease progression dp develops symptoms. If the individual is asymptomatic, this will return -1.

Missing docstring.

Missing docstring for try_to_infect!. Check Documenter's build log for details.

Missing docstring.

Missing docstring for update_individual!(::Individual, ::Int16, ::Simulation). Check Documenter's build log for details.