Defines a list specifying the structure of the observation model. Custom settings can be supplied which override the defaults.

obs_opts(
family = "negbin",
weight = 1,
week_effect = TRUE,
week_length = 7,
scale = list()
)

## Arguments

family Character string defining the observation model. Options are Negative binomial ("negbin"), the default, and Poisson. Numeric, defaults to 1. Weight to give the observed data in the log density. Logical defaulting to TRUE. Should a day of the week effect be used in the observation model. Numeric assumed length of the week in days, defaulting to 7 days. This can be modified if data aggregated over a period other than a week or if data has a non-weekly periodicity. List, defaulting to an empty list. Should an scaling factor be applied to map latent infections (convolved to date of report). If none empty a mean (mean) and standard deviation (sd) needs to be supplied defining the normally distributed scaling factor.

## Value

A list of observation model settings.

## Examples

# default settings
obs_opts()
#> $family #> [1] "negbin" #> #>$weight
#> [1] 1
#>
#> $week_effect #> [1] TRUE #> #>$week_length
#> [1] 7
#>
#> $scale #> list() #> # Turn off day of the week effect obs_opts(week_effect = TRUE) #>$family
#> [1] "negbin"
#>
#> $weight #> [1] 1 #> #>$week_effect
#> [1] TRUE
#>
#> $week_length #> [1] 7 #> #>$scale
#> list()
#>

# Scale reported data
obs_opts(scale = list(mean = 0.2, sd = 0.02))
#> $family #> [1] "negbin" #> #>$weight
#> [1] 1
#>
#> $week_effect #> [1] TRUE #> #>$week_length
#> [1] 7
#>
#> $scale #>$scale$mean #> [1] 0.2 #> #>$scale\$sd
#> [1] 0.02
#>
#>