PlotFertilityRatesStats.Rd
Plot Fertility Rates Statistics
PlotFertilityRatesStats(results, se = FALSE, type = "lines", log = TRUE)
Results list (as returned by RunExperiments()
)
Whether to show standard error or standard deviation confidence intervals.
Note: the se
parameter does not apply to the "boxplot" type.
Plot type (options = "lines", "ribbon", "boxplot")
Use log scale for rates (default = TRUE). Applies only to "boxplot" type.
ggplot grob
if (FALSE) {
library(pacehrh)
pacehrh::InitializePopulation()
pacehrh::InitializeScenarios()
pacehrh::InitializeStochasticParameters()
pacehrh::InitializeSeasonality()
scenario <- "ScenarioName"
results <-
pacehrh::RunExperiments(
scenarioName = scenario,
trials = 100
)
g <- pacehrh::PlotFertilityRatesStats(results, type = "boxplot", log = FALSE)
print(g)
g <- pacehrh::PlotFertilityRatesStats(results, type = "boxplot", log = TRUE)
print(g)
g <- pacehrh::PlotFertilityRatesStats(results, se = FALSE, type = "lines")
print(g)
g <- pacehrh::PlotFertilityRatesStats(results, se = TRUE, type = "lines")
print(g)
g <- pacehrh::PlotFertilityRatesStats(results, se = FALSE, type = "ribbon")
print(g)
g <- pacehrh::PlotFertilityRatesStats(results, se = TRUE, type = "ribbon")
print(g)
}