Plot seroincidence.by
log-likelihoods
Source: R/autoplot.seroincidence.by.R
autoplot.seroincidence.by.Rd
Plots log-likelihood curves by stratum, for seroincidence.by
objects
Arguments
- object
a '"seroincidence.by"' object (from
est.incidence.by()
)- ncol
number of columns to use for panel of plots
- ...
Arguments passed on to
autoplot.seroincidence
log_x
should the x-axis be on a logarithmic scale (
TRUE
) or linear scale (FALSE
, default)?
Value
an object of class "ggarrange"
, which is a ggplot2::ggplot()
or a list()
of ggplot2::ggplot()
s.
Examples
# \donttest{
library(dplyr)
library(ggplot2)
xs_data <-
sees_pop_data_pk_100
curve <-
typhoid_curves_nostrat_100 %>%
filter(antigen_iso %in% c("HlyE_IgA", "HlyE_IgG"))
noise <-
example_noise_params_pk
est2 <- est.incidence.by(
strata = c("catchment"),
pop_data = xs_data,
curve_params = curve,
noise_params = noise,
antigen_isos = c("HlyE_IgG", "HlyE_IgA"),
#num_cores = 8, #Allow for parallel processing to decrease run time
build_graph = TRUE
)
#> Warning: curve_params is missing all strata variables, and will be used unstratified.
#>
#> To avoid this warning, specify the desired set of stratifying variables in the `curve_strata_varnames` and `noise_strata_varnames` arguments to `est.incidence.by()`.
#> Warning: noise_params is missing all strata variables, and will be used unstratified.
#>
#> To avoid this warning, specify the desired set of stratifying variables in the `curve_strata_varnames` and `noise_strata_varnames` arguments to `est.incidence.by()`.
# Plot the log-likelihood curve
autoplot(est2)
# }