Skip to content

Commit

Permalink
move changes to Rmd.orig
Browse files Browse the repository at this point in the history
  • Loading branch information
kaitejohnson committed Oct 1, 2024
1 parent 376835e commit 3c0d6ae
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion vignettes/EpiNow2.Rmd.orig
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ library(EpiNow2)

### Reporting delays, incubation period and generation time

Distributions can be supplied in two ways. First, one can supplying delay data to `estimate_delay()`, where a subsampled bootstrapped lognormal will be fit to account for uncertainty in the observed data without being biased by changes in incidence (see `?EpiNow2::estimate_delay()`).
Distributions can be supplied in two ways. First, one can supply delay data to `estimate_delay()`, where a subsampled bootstrapped lognormal will be fit to account for uncertainty in the observed data without being biased by changes in incidence (see `?EpiNow2::estimate_delay()`).

Second, one can specify predetermined delays with uncertainty using the distribution functions such as `Gamma` or `Lognormal`. An arbitrary number of delay distributions are supported in `dist_spec()` with a common use case being an incubation period followed by a reporting delay. For more information on specifying distributions see (see `?EpiNow2::Distributions`).

Expand All @@ -61,6 +61,20 @@ example_generation_time
example_incubation_period
```

Users can also pass a non-parametric delay distribution vector using the `NonParametric` option
for both the generation interval and reporting delays. It is important to note that if doing so,
both delay distributions are 0-indexed, meaning the first element corresponds to the probability mass
at day 0 of an individual's infection. Because the discretised renewal equation doesn't support mass on day 0, the generation interval should be passed in as a 0-indexed vector with a mass of zero on day 0.
If this is not the case, a warning will indicate that the vector is being left-truncated and renormalized.

```{r}
example_non_parametric_gi <- NonParametric(pmf = c(0, 0.3, 0.5, 0.2))

example_non_parametric_delay <- NonParametric(pmf = c(0.01, 0.1, 0.5, 0.3, 0.09))
```
These distributions are passed to downstream functions in the same way that the
parametric distributions are.

Now, to the functions.

### [epinow()](https://epiforecasts.io/EpiNow2/reference/epinow.html)
Expand Down

0 comments on commit 3c0d6ae

Please sign in to comment.