Plotting
Overview Structs
GEMS.ActiveDarkFigure
GEMS.AggregatedSettingAgeContacts
GEMS.CompartmentFill
GEMS.CumulativeCases
GEMS.CumulativeDiseaseProgressions
GEMS.CumulativeIsolations
GEMS.CustomLoggerPlot
GEMS.DetectedCases
GEMS.EffectiveReproduction
GEMS.GMTWrapper
GEMS.GenerationTime
GEMS.HospitalOccupancy
GEMS.HouseholdAttackRate
GEMS.Incidence
GEMS.IncubationHistogram
GEMS.InfectionDuration
GEMS.InfectiousHistogram
GEMS.LatencyHistogram
GEMS.ObservedReproduction
GEMS.ObservedSerialInterval
GEMS.PopulationPyramid
GEMS.SettingAgeContacts
GEMS.SettingSizeDistribution
GEMS.SimulationPlot
GEMS.SymptomCategories
GEMS.TestPositiveRate
GEMS.TickCases
GEMS.TickCasesBySetting
GEMS.TickTests
GEMS.TimeToDetection
GEMS.TotalTests
Overview Functions
GEMS.emptyplot
GEMS.gemsplot
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.generate
GEMS.plotseries!
GEMS.saveplot
GEMS.splitlabel
GEMS.splitplot
Plotting
GEMS.gemsplot
— Functiongemsplot(rd::ResultData; type::Symbol = :nothing, plotargs...)
gemsplot(bd::BatchData; type::Symbol = :nothing, combined::Symbol = :all, plotargs...)
gemsplot(rd::Vector{ResultData}; type::Symbol = :nothing, combined::Symbol = :all, plotargs...)
Facilitates the usage of GEMS' inbuilt plots. Just pass the name of the plot-type as a Symbol
(must be exactly the same as the respective SimulationPlot
-struct). The plotargs...
can be any keyworded argument that is available in the standard Plots.jl
package.
You can pass a ResultData
object to get a plot for one simulation run or even pass a vector of ResultData
objects or even a BatchData
object. Passing data of multiple simulation runs (ResultData
-vector or BatchData
) will generate the respective plot with the data of all simulation runs inside. E.g., the :TickCases
plot will show one line for each run. Simulations with the same label
attribute will be grouped using the same color.
The keyword combined
(only applicable for ResultData
-vectors or BatchData
-objects) determines whether all data is combined in a single plot (:all
), each simulation run gets its own subplot (:single
), or the plots are separated by label (:bylabel
). Note: There might be plots without a multi-plot implementation. They will always be printed as if combined = :single
was passed. Check the table below to see which plots are available for single- and multiplots.
Parameters
rd/bd
: Data object to plot. Can beResultData
,Vector{ResultData}
orBatchData
type = :nothing
(optional): Plot type (instantiates a plot with the exact same struct name). You can pass a tuple of plots to generate one graph with multiple visualizationscombined::Symbol = :all
(optional): all data in one plot (:all
), all individual plots (:singe
), plot separated by label (:bylabel
).plotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Plot using thePlots.jl
package's struct.
Examples
Given that rd
is a valid ResultData
object that came out of a simulation, you can plot a summary like this:
gemsplot(rd)
If you want a specific plot, say the cases-per-tick plot, try this and add a custom title:
gemsplot(rd, type = :TickCases, title = "My Tick Case Plot")
You can also generate multiple plots in one figure like so:
gemsplot(rd, type = (:CompartmentFill, :EffectiveReproduction), layout = (2,1))
The layout
keyword makes the plots appear on top of each other in stead of side-by-side.
Generate a multi-plot for a vector of ResultData
objects and separate plots by label like so:
# assuming you have a baseline, and a lockdown scenario with two simulation runs each.
# the simulations of these ResultData objects must have the same label ("Baseline" and "Lockdown") to group them
rds = [rd_baseline_1, rd_baseline_2, rd_lockdown_1, rd_lockdown_2]
gemsplot(rds, type = :EffectiveReproduction, combined = :bylabel)
Plot Types
The following plot types can be generated using the gemsplot()
function. The mutli-plot column describes which plots can work with ResultData
-vector or BatchData
-objects. Some of the plots have keyword arguments that are only applicable to that very plot.
Type | Description | Multi-Plot | Plot-Specific Parameters |
---|---|---|---|
:ActiveDarkFigure | Fraction of current infections per tick that are "known"/detected at that tick. | Yes | |
:AggregatedSettingAgeContacts | Age-X-Age contact matrix for all setting types in the simulation (e.g., Household ). | No | settingtype::DataType : Filter for specific setting type (e.g., Household ), show_values::Bool : Enable or disable printed values in cells. |
:CompartmentFill | Current number of individuals per compartment (classic SEIR curves). | No | |
:CumulativeCases | Summed-up cases over time. | Yes | |
:CumulativeDiseaseProgressions | Number of people in a certain disease state at a given tick after their exposure. | No | |
:CumulativeIsolations | Number of currently isolated individuals over time. | Yes | series::Symbol : Filter for :workers , :students , :other , or :all |
:CustomLoggerPlot | CustomLogger values. One subplot per logging function in the multi-plot variant. | Yes | |
:DetectedCases | New detected cases per time step. | No | |
:EffectiveReproduction | Effective reproduction number (R_eff) over time. | Yes | |
:GenerationTime | Mean generation time over time. | Yes | |
:HospitalOccupancy | Number of hospitalized, ventilated, and ICU-admitted indivudual over time. | No | |
:HouseholdAttackRate | In-Household attack rate per household size. | Yes | |
:Incidence | Indicende over time by 10-year age group (stacked chart). | No | |
:IncubationHistogram | Histogram of incubation period duratons. | No | |
:InfectionDuration | Histogram of total infection durations. | Yes | |
:InfectiousHistogram | Histogram of infectious period duratons. | No | |
:LatencyHistogram | Histogram of latency period durations. | No | |
:ObservedReproduction | Observed rffective reproduction number (R_eff) over time (based on detected cases). | No | |
:ObservedSerialInterval | Observed serial interval (SI) over time (based on detected cases). | No | |
:PopulationPyramid | Population Pyramid by age and sex. | No | |
:SettingSizeDistribution | Histograms of setting sizes for all setting types (e.g., Household s) | No | |
:SymptomCategories | Heatmap of the fraction of symptom categories (asymptomatic, mild, severe...) by age. | No | |
:TestPositiveRate | Fraction of all performed tests that were positive per test type (e.g., PCR ). | No | |
:TickCases | New cases per time step. For single sim. also with new infectious, removed, dead. | Yes | |
:TickCasesBySetting | New cases stratified by setting type (e.g., Household or Office ) | No | |
:TickTests | Performed tests per time step, including positive and total tests and reported cases. | No | |
:TimeToDetection | Average time between exposure and detected for all infections over time. | No | |
:TotalTests | Total number of performed tests per test type (e.g., PCR ) | Yes |
Some Useful Keyword Arguments
Here are some examples of the Plots.jl
package's keyword arguments that you can also pass to the gemsplot()
function and might find helpful:
xlims = (0, 100)
: Setting the X-axis range between 0 and 100ylims = (0, 200)
: Setting the Y-axis range between 0 and 200size = (300, 400)
: Resizing the plotplot_title = "My New Title"
: Changing the plot titlexlabel = "New X-label"
: Changing the x-axis labelylabel = "New Y-label"
: Changing the y-axis labellegend = :topright
: Changing the legend position (false
to disable)aspect_ratio = :equal
: Having the axis of equal size
Please consult the Plots.jl
package documentation for a comprehensive list
GEMS.emptyplot
— Methodemptyplot(message::String)
Returns an empty plot with the argument message as a text overlay. This can be used as a default for plot-generate()-functions, if no data is available in the ResultData
object.
GEMS.plotseries!
— Functionplotseries!(p::Plots.Plot, extract_function::Function, rds::Vector{ResultData}; plotargs...)
Extends a plot and adds data grouped by the labels of the ResultData
objects. The extract_function
argument must be a one-argument function that is the called with a single ResultData
object. It must return the data series that should be plotted.
Parameters
p::Plots.Plot
: Input plot object to extendextract_function::Function
: One-argument lambda function that will be called with each of theResultData
objects in the input vector. This function must return a vector of numberical values that is being added as a line series to input plotp
.rds::Vector{ResultData}
: Vector ofResultData
objects to plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Plot using thePlots.jl
package's struct.
Example
This code generates a plot of the effective reproduction number with one line per ResultData
object and grouped by label
.
p = plotseries!(plot(), rd -> effectiveR(rd)[!,"rolling_R"], rds)
GEMS.saveplot
— Functionsaveplot(plot::Plots.Plot, path::AbstractString)
Stores a plot from the juliaplots package to the provided path.
saveplot(plot::GMTWrapper, path::AbstractString)
Copies a GMT plot from the temp folder into the provided path (removes the temporary file).
GEMS.splitlabel
— Functionsplitlabel(plt::SimulationPlot, rds::Vector{ResultData}; plotargs...)
Returns a split side-by-side plot for multiple ResultData
objects but groups simulation runs by label. If you have 2 scenarios with 10 simulation runs each, this function will generate two plots with 10 data series each.
plt::SimulationPlot
: Simulation plot struct (e.g.TickCases()
)rds::Vector{ResultData}
: Vector ofResultData
objects to plot (requires therd
objects to have thelabel
attribute)plotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Plot using thePlots.jl
package's struct.
GEMS.splitplot
— Functionsplitplot(plt::SimulationPlot, rds::Vector{ResultData}; plotargs...)
Returns a split side-by-side plot for multiple ResultData
objects.
Parameters
plt::SimulationPlot
: Simulation plot struct (e.g.TickCases()
)rds::Vector{ResultData}
: Vector ofResultData
objects to plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Plot using thePlots.jl
package's struct.
Plot Types
GEMS.ActiveDarkFigure
— TypeActiveDarkFigure <: SimulationPlot
A simulation plot type for generating an active-darkfigure-per-tick plot.
GEMS.generate
— Methodgenerate(plt::ActiveDarkFigure, rd::ResultData; plotargs...)
Generates and returns a active-darkfigure-per-tick plot for a provided ResultData
object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::ActiveDarkFigure
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Active Dark Figure plot
GEMS.AggregatedSettingAgeContacts
— TypeAggregatedSettingAgeContacts <: SimulationPlot
A simulation plot type for sampling contacts from the model and build an age group
x age group
matrix for a given Setting type. The plot displays aggregated age groups and their mean number of contacts.
GEMS.generate
— Methodgenerate(plt::AggregatedSettingAgeContacts, rd::ResultData;
settingtype::Union{DataType, Nothing} = nothing, plotargs...)
Generates and returns an age group
x age group
matrix from sampled contacts for a given Setting type. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::AggregatedSettingAgeContacts
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotsettingtype::Union{DataType, Nothing} = nothing
(optional): Setting type (e.g. "Household"). If nothing is passed, all setting types in theResultData
object are being ploted.show_values = true
(optional): If true, values will be printed in the contact matrixplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Aggregated Setting Age Contacts plot
GEMS.CompartmentFill
— TypeCompartmentFill <: SimulationPlot
A simulation plot type for generating a cumulative infections plot.
GEMS.generate
— Methodgenerate(plt::CompartmentFill, rd::ResultData; plotargs...)
Generates and returns a plot of the current compartment fill for a provided ResultData object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::CompartmentFill
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Compartment Fill plot
GEMS.CumulativeCases
— TypeCumulativeCases <: SimulationPlot
A simulation plot type for generating a cumulative infections plot.
GEMS.generate
— Methodgenerate(plt::CumulativeCases, rd::ResultData; plotargs...)
Generates and returns a cumulative infections plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::CumulativeCases
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Cumulative Cases plot
GEMS.CumulativeDiseaseProgressions
— TypeCumulativeDiseaseProgressions <: SimulationPlot
A simulation plot type for generating a stacked bar chart on the cumulative disease progression.
GEMS.generate
— Methodgenerate(plt::CumulativeDiseaseProgressions, rd::ResultData; plotargs...)
Generates a stacked bar chart of cumulative disease progressions for all infections. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::CumulativeDiseaseProgressions
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Cumulative Disease Progressions plot
GEMS.CumulativeIsolations
— TypeCumulativeIsolations <: SimulationPlot
A simulation plot type for generating a plot displaying the cumulative number of individuals currently in isolation.
GEMS.generate
— Methodgenerate(plt::CumulativeIsolations, rd::ResultData; plotargs...)
Generates a plot for the cumulative number of isolated individuals per tick. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::CumulativeIsolations
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Cumulative Isolations plot
GEMS.CustomLoggerPlot
— TypeCustomLoggerPlot <: SimulationPlot
A simulation plot type for generating a time series plot displaying values stored in a ResultData
s CustomLogger
dataframe.
GEMS.generate
— Methodgenerate(plt::CustomLoggerPlot, rd::ResultData; plotargs...)
Generates and returns a plot for the values contained in the custom logger of a ResultData
object. It will contain one individual plot per function that was passed to the custom logger. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package. However, be aware that the keyword arguments might be applied to each of the subplots individually.
Parameters
plt::CustomLoggerPlot
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Custom Logger Plot plot
GEMS.DetectedCases
— TypeDetectedCases <: SimulationPlot
A simulation plot type for generating a new-DETECTED-cases-per-tick plot.
GEMS.generate
— Methodgenerate(plt::DetectedCases, rd::ResultData; plotargs...)
Generates and returns a new-DETECTED-cases-per-tick plot for a provided simulation object. Sorts infections dataframe by test_tick
and filters for tested individuals. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::DetectedCases
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Detected Cases plot
GEMS.EffectiveReproduction
— TypeEffectiveReproduction <: SimulationPlot
A simulation plot type for generating an effective reproduction number plot.
GEMS.generate
— Methodgenerate(plt::EffectiveReproduction, rd::ResultData; plotargs...)
Generates a plot for the effective reproduction number per tick. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::EffectiveReproduction
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Effective Reproduction Number plot
GEMS.GMTWrapper
— TypeGMTWrapper
Wrapper-struct to inform saveplot function about the existance of a GMT-generated plot in the temp-folder (path_to_map
).
GEMS.GenerationTime
— TypeGenerationTime <: SimulationPlot
A simulation plot type for generating a generation-time-per-tick.
GEMS.generate
— Methodgenerate(plt::GenerationTime, rd::ResultData; plotargs...)
Generates and returns a generation-time-per-tick plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::GenerationTime
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Generation Time plot
GEMS.HospitalOccupancy
— TypeHospitalOccupancy <: SimulationPlot
A simulation plot type for generating a plot with hospitalization numbers etc.
GEMS.generate
— Methodgenerate(plt::HospitalOccupancy, rd::ResultData; plotargs...)
Generates a plot of the number of hospitalized, ventilated and ICU admitted agents for each tick. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::HospitalOccupancy
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Hospital Occupancy plot
GEMS.HouseholdAttackRate
— TypeHouseholdAttackRate <: SimulationPlot
A simulation plot type for generating a household-attack-rate plot.
GEMS.generate
— Methodgenerate(plt::HouseholdAttackRate, rd::ResultData; plotargs...)
Generates and returns a household-attack-rate plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package. However, be aware that the keyword arguments might be applied to each of the subplots individually.
Parameters
plt::HouseholdAttackRate
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Household Attack Rate plot
GEMS.Incidence
— TypeIncidence <: SimulationPlot
A simulation plot type for generating an incidence plot.
GEMS.generate
— Methodgenerate(plt::Incidence, rd::ResultData; plotargs...)
Generates an age-stratified incidence plot. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::Incidence
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Incidence plot
GEMS.IncubationHistogram
— TypeIncubationHistogram <: SimulationPlot
A simulation plot type for generating the distribution of incubation period lengths for symptomatic individuals.
GEMS.generate
— Methodgenerate(plt::IncubationHistogram, rd::ResultData; plotargs...)
Generates a histrogram of the incubation period distribution (time to symptoms) of collected infections. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Note that this only shows the incubation period for symptomatic individuals!
Parameters
plt::IncubationHistogram
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Infectious Histogram plot
GEMS.InfectionDuration
— TypeInfectionDuration <: SimulationPlot
A simulation plot type for visualizing the distribution of infection durations as a histogram.
GEMS.generate
— Methodgenerate(plt::InfectionDuration, rd::ResultData; plotargs...)
Generates and returns a histogram of the total infection durations in ticks. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::InfectionDuration
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Infection Duration plot
GEMS.InfectiousHistogram
— TypeInfectiousHistogram <: SimulationPlot
A simulation plot type for generating the distribution of infectious period lengths.
GEMS.generate
— Methodgenerate(plt::InfectiousHistogram, rd::ResultData; plotargs...)
Generates a histrogram of the infectious period distribution of collected infections. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::InfectiousHistogram
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Infectious Histogram plot
GEMS.LatencyHistogram
— TypeLatencyHistogram <: SimulationPlot
A simulation plot type for generating the distribution of latency period lengths.
GEMS.generate
— Methodgenerate(plt::LatencyHistogram, rd::ResultData; plotargs...)
Generates a histrogram of the latency period distribution of collected infections. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::LatencyHistogram
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Latency Histogram plot
GEMS.ObservedReproduction
— TypeObservedReproduction <: SimulationPlot
A simulation plot type for generating a observed-reproduction-number-plot.
GEMS.generate
— Method generate(plt::ObservedReproduction, rd::ResultData; plotargs...)
Generates a plot for the effective reproduction number per tick. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::ObservedReproduction
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Observed Reproduction Number plot
GEMS.ObservedSerialInterval
— TypeObservedSerialInterval <: SimulationPlot
A simulation plot type for generating a observed-serial-interval-plot.
GEMS.generate
— Methodgenerate(plt::ObservedSerialInterval, rd::ResultData; plotargs...)
Generates a plot for the estimation on the observed serial interval per tick. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::ObservedSerialInterval
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Observed Serial Interval plot
GEMS.PopulationPyramid
— TypePopulationPyramid <: SimulationPlot
A simulation plot type for generating a population pyramid for the associated population model.
GEMS.generate
— Methodgenerate(plt::PopulationPyramid, rd::ResultData; plotargs...)
Generates population pyramid for a the associated population model.
The current implementation does not offer the option for additional keyworded arguments. The plotargs...
argument is just a placeholder.
Parameters
plt::PopulationPyramid
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): PLACEHOLDER. Currently not implemented.
Returns
Plots.Plot
: Population Pyramid plot
GEMS.SettingAgeContacts
— TypeSettingAgeContacts <: SimulationPlot
A simulation plot type for sampling contacts from the model and build an age
x age
matrix for a given Setting type.
GEMS.generate
— Methodgenerate(plt::SettingAgeContacts, rd::ResultData; plotargs...)
Generates and returns an age
x age
matrix from sampled contacts for a given Setting type. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::SettingAgeContacts
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Setting Age Contacts plot
GEMS.SettingSizeDistribution
— TypeSettingSizeDistribution <: SimulationPlot
A simulation plot type for generating a population pyramid for the associated population model.
GEMS.generate
— Methodgenerate(plt::SettingSizeDistribution, rd::ResultData; plotargs...)
Generates the setting size distributions for all included settings. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::SettingSizeDistribution
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Setting Size Distribution plot
GEMS.SimulationPlot
— TypeSupertype for all plots that go into single-run simulation reports
GEMS.generate
— MethodAbstract wrapper function for all simulation report plots. Requires concrete implementation in subtypes
GEMS.SymptomCategories
— TypeSymptomCategories <: SimulationPlot
A simulation plot type for visualizing the symptom categories of infections by age.
GEMS.generate
— Methodgenerate(plt::SymptomCategories, rd::ResultData; plotargs...)
Generates and returns a symptom_category
x age
matrix as heatmap. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::SymptomCategories
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Symptom Categories plot
GEMS.TestPositiveRate
— TypeTestPositiveRate <: SimulationPlot
A simulation plot type for generating a tests-positive-rate-per-tick plot.
GEMS.generate
— Methodgenerate(plt::TestPositiveRate, rd::ResultData; plotargs...)
Generates and returns a tests-positive-rate-per-tick plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TestPositiveRate
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Test Positive Rate plot
GEMS.TickCases
— TypeTickCases <: SimulationPlot
A simulation plot type for generating a new-cases-per-tick plot.
GEMS.generate
— Methodgenerate(plt::TickCases, rd::ResultData; plotargs...)
Generates and returns a new-cases-per-tick plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TickCases
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Tick Cases plot
GEMS.TickCasesBySetting
— TypeTickCasesBySetting <: SimulationPlot
A simulation plot type for generating tick cases for each included setting type.
GEMS.generate
— Methodgenerate(plt::TickCasesBySetting, rd::ResultData; plotargs...)
Generates a plot of tick cases for each included setting type. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TickCasesBySetting
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Tick Cases By Setting plot
GEMS.TickTests
— TypeTickTests <: SimulationPlot
A simulation plot type for generating a new-tests-per-tick plot.
GEMS.generate
— Methodgenerate(plt::TickTests, rd::ResultData; plotargs...)
Generates and returns a tests-per-tick plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TickTests
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Tick Tests plot
GEMS.TimeToDetection
— TypeTimeToDetection <: SimulationPlot
A simulation plot type for generating a time-to-detection plot.
GEMS.generate
— Methodgenerate(plt::TimeToDetection, rd::ResultData; plotargs...)
Generates and returns a time-to-detection plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TimeToDetection
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Time To Detection plot
GEMS.TotalTests
— TypeTotalTests <: SimulationPlot
A simulation plot type for generating a total-tests-per-tick plot.
GEMS.generate
— Methodgenerate(plt::TotalTests, rd::ResultData; plotargs...)
Generates and returns a total-tests-per-tick plot for a provided simulation object. You can pass any additional keyword arguments using plotargs...
that are available in the Plots.jl
package.
Parameters
plt::TotalTests
:SimulationPlot
struct with meta data (i.e. title, description, and filename)rd::ResultData
: Input data used to generate plotplotargs...
(optional): Any argument that theplot()
function of thePlots.jl
package can take.
Returns
Plots.Plot
: Total Tests plot