Skip to contents

Plot r-hats convergence criteria for the specified model

Usage

plot_rhats(seromodel, serosurvey, par_name = "foi_expanded", size_text = 11)

Arguments

seromodel

stan_fit object obtained from sampling a model with fit_seromode

serosurvey
survey_year

Year in which the survey took place (only needed to plot time models)

age_min

Floor value of the average between age_min and age_max

age_max

The size of the sample

sample_size

Number of samples for each age group

n_seropositive

Number of positive samples for each age group

par_name

String specifying the parameter to be extracted from seromodel

size_text

Size of text for plotting (base_size in ggplot2)

Value

ggplot object showing the r-hats of the model to be compared with the convergence criteria (horizontal dashed line)