Skip to content

Commit c7bcb15

Browse files
committed
differences for PR #187
1 parent d5f0185 commit c7bcb15

29 files changed

+161
-6411
lines changed

config.yaml

Lines changed: 0 additions & 86 deletions
This file was deleted.

create-forecast.md

Lines changed: 44 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,24 @@ estimates <- EpiNow2::epinow(
140140
)
141141
```
142142

143+
``` output
144+
WARN [2025-10-13 19:42:39] epinow: There were 420 transitions after warmup that exceeded the maximum treedepth. Increase max_treedepth above 12. See
145+
https://mc-stan.org/misc/warnings.html#maximum-treedepth-exceeded -
146+
WARN [2025-10-13 19:42:39] epinow: There were 1 chains where the estimated Bayesian Fraction of Missing Information was low. See
147+
https://mc-stan.org/misc/warnings.html#bfmi-low -
148+
WARN [2025-10-13 19:42:39] epinow: Examine the pairs() plot to diagnose sampling problems
149+
-
150+
WARN [2025-10-13 19:42:40] epinow: The largest R-hat is NA, indicating chains have not mixed.
151+
Running the chains for more iterations may help. See
152+
https://mc-stan.org/misc/warnings.html#r-hat -
153+
WARN [2025-10-13 19:42:41] epinow: Bulk Effective Samples Size (ESS) is too low, indicating posterior means and medians may be unreliable.
154+
Running the chains for more iterations may help. See
155+
https://mc-stan.org/misc/warnings.html#bulk-ess -
156+
WARN [2025-10-13 19:42:43] epinow: Tail Effective Samples Size (ESS) is too low, indicating posterior variances and tail quantiles may be unreliable.
157+
Running the chains for more iterations may help. See
158+
https://mc-stan.org/misc/warnings.html#tail-ess -
159+
```
160+
143161
::::::::::::::::::::::::::::::::: callout
144162

145163
### Do not wait for this to complete!
@@ -196,18 +214,27 @@ estimates <- EpiNow2::epinow(
196214
# Add observation model
197215
obs = EpiNow2::obs_opts(scale = obs_scale)
198216
)
217+
```
218+
219+
``` output
220+
WARN [2025-10-13 19:47:14] epinow: There were 17 transitions after warmup that exceeded the maximum treedepth. Increase max_treedepth above 12. See
221+
https://mc-stan.org/misc/warnings.html#maximum-treedepth-exceeded -
222+
WARN [2025-10-13 19:47:14] epinow: Examine the pairs() plot to diagnose sampling problems
223+
-
224+
```
199225

226+
``` r
200227
base::summary(estimates)
201228
```
202229

203230
``` output
204231
measure estimate
205232
<char> <char>
206-
1: New infections per day 20133 (13440 -- 30167)
207-
2: Expected change in reports Likely decreasing
208-
3: Effective reproduction no. 0.96 (0.76 -- 1.2)
209-
4: Rate of growth -0.013 (-0.095 -- 0.067)
210-
5: Doubling/halving time (days) -55 (10 -- -7.3)
233+
1: New infections per day 20243 (13422 -- 30520)
234+
2: Expected change in reports Stable
235+
3: Effective reproduction no. 0.97 (0.77 -- 1.2)
236+
4: Rate of growth -0.011 (-0.092 -- 0.067)
237+
5: Doubling/halving time (days) -66 (10 -- -7.5)
211238
```
212239

213240

@@ -291,12 +318,6 @@ estimate_cases_to_deaths <- EpiNow2::estimate_secondary(
291318
)
292319
```
293320

294-
``` output
295-
WARN [2025-09-25 13:36:12] estimate_secondary (chain: 1): Tail Effective Samples Size (ESS) is too low, indicating posterior variances and tail quantiles may be unreliable.
296-
Running the chains for more iterations may help. See
297-
https://mc-stan.org/misc/warnings.html#tail-ess -
298-
```
299-
300321

301322
::::::::::::::::::::::::::::::::::::: callout
302323

@@ -527,21 +548,29 @@ ebola_estimates <- EpiNow2::epinow(
527548
# horizon needs to be 14 days to create two week forecast (default is 7 days)
528549
forecast = EpiNow2::forecast_opts(horizon = 14)
529550
)
551+
```
530552

553+
``` output
554+
WARN [2025-10-13 19:48:18] epinow: Tail Effective Samples Size (ESS) is too low, indicating posterior variances and tail quantiles may be unreliable.
555+
Running the chains for more iterations may help. See
556+
https://mc-stan.org/misc/warnings.html#tail-ess -
557+
```
558+
559+
``` r
531560
summary(ebola_estimates)
532561
```
533562

534563
``` output
535564
measure estimate
536565
<char> <char>
537-
1: New infections per day 91 (47 -- 190)
566+
1: New infections per day 93 (47 -- 194)
538567
2: Expected change in reports Increasing
539568
3: Effective reproduction no. 1.6 (1.1 -- 2.4)
540-
4: Rate of growth 0.041 (0.0027 -- 0.088)
541-
5: Doubling/halving time (days) 17 (7.9 -- 260)
569+
4: Rate of growth 0.042 (0.0023 -- 0.088)
570+
5: Doubling/halving time (days) 17 (7.8 -- 300)
542571
```
543572

544-
The effective reproduction number $R_t$ estimate (on the last date of the data) is 1.6 (1.1 -- 2.4). The exponential growth rate of case numbers is 0.041 (0.0027 -- 0.088).
573+
The effective reproduction number $R_t$ estimate (on the last date of the data) is 1.6 (1.1 -- 2.4). The exponential growth rate of case numbers is 0.042 (0.0023 -- 0.088).
545574

546575
Visualize the estimates:
547576

delays-functions.md

Lines changed: 2 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,8 @@ epiparameter::generate(covid_serialint, times = 10)
167167
```
168168

169169
``` output
170-
[1] 3.270725 1.934659 3.429970 4.610215 1.973068 1.984880 6.728371
171-
[8] 2.991406 11.102558 9.452121
170+
[1] 6.617295 4.104120 5.396495 7.536144 4.830989 3.930958 3.021253 6.125172
171+
[9] 3.773901 3.134338
172172
```
173173

174174
::::::::: instructor
@@ -762,27 +762,7 @@ epinow_estimates_cgi <- EpiNow2::epinow(
762762
generation_time = EpiNow2::generation_time_opts(covid_serial_interval),
763763
delays = EpiNow2::delay_opts(covid_incubation_time)
764764
)
765-
```
766765

767-
``` output
768-
WARN [2025-10-10 18:10:57] epinow: There were 336 transitions after warmup that exceeded the maximum treedepth. Increase max_treedepth above 12. See
769-
https://mc-stan.org/misc/warnings.html#maximum-treedepth-exceeded -
770-
WARN [2025-10-10 18:10:57] epinow: There were 1 chains where the estimated Bayesian Fraction of Missing Information was low. See
771-
https://mc-stan.org/misc/warnings.html#bfmi-low -
772-
WARN [2025-10-10 18:10:57] epinow: Examine the pairs() plot to diagnose sampling problems
773-
-
774-
WARN [2025-10-10 18:10:58] epinow: The largest R-hat is NA, indicating chains have not mixed.
775-
Running the chains for more iterations may help. See
776-
https://mc-stan.org/misc/warnings.html#r-hat -
777-
WARN [2025-10-10 18:10:59] epinow: Bulk Effective Samples Size (ESS) is too low, indicating posterior means and medians may be unreliable.
778-
Running the chains for more iterations may help. See
779-
https://mc-stan.org/misc/warnings.html#bulk-ess -
780-
WARN [2025-10-10 18:11:00] epinow: Tail Effective Samples Size (ESS) is too low, indicating posterior variances and tail quantiles may be unreliable.
781-
Running the chains for more iterations may help. See
782-
https://mc-stan.org/misc/warnings.html#tail-ess -
783-
```
784-
785-
``` r
786766
base::plot(epinow_estimates_cgi)
787767
```
788768

@@ -931,17 +911,7 @@ epinow_estimates_egi <- EpiNow2::epinow(
931911
generation_time = EpiNow2::generation_time_opts(serial_interval_ebola),
932912
delays = EpiNow2::delay_opts(incubation_period_ebola)
933913
)
934-
```
935914

936-
``` output
937-
WARN [2025-10-10 18:11:52] epinow: There were 3 divergent transitions after warmup. See
938-
https://mc-stan.org/misc/warnings.html#divergent-transitions-after-warmup
939-
to find out why this is a problem and how to eliminate them. -
940-
WARN [2025-10-10 18:11:52] epinow: Examine the pairs() plot to diagnose sampling problems
941-
-
942-
```
943-
944-
``` r
945915
plot(epinow_estimates_egi)
946916
```
947917

0 Bytes
Loading
-141 Bytes
Loading
148 Bytes
Loading
-4.97 KB
Binary file not shown.
-49 KB
Binary file not shown.
-927 Bytes
Loading
-29.8 KB
Binary file not shown.

0 commit comments

Comments
 (0)