Skip to content

Commit

Permalink
accumulate after truncation
Browse files Browse the repository at this point in the history
  • Loading branch information
sbfnk committed Nov 23, 2024
1 parent 9a8ef8e commit abb8d1c
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions inst/stan/estimate_secondary.stan
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,6 @@ transformed parameters {
secondary = day_of_week_effect(secondary, day_of_week, day_of_week_simplex);
}

// accumulate reports
if (any_accumulate) {
profile("accumulate") {
secondary = accumulate_reports(secondary, accumulate);
}
}

// truncate near time cases to observed reports
if (trunc_id) {
vector[delay_type_max[trunc_id]] trunc_rev_cmf = get_delay_rev_pmf(
Expand All @@ -90,6 +83,13 @@ transformed parameters {
);
secondary = truncate_obs(secondary, trunc_rev_cmf, 0);
}

// accumulate reports
if (any_accumulate) {
profile("accumulate") {
secondary = accumulate_reports(secondary, accumulate);
}
}
}

model {
Expand Down

0 comments on commit abb8d1c

Please sign in to comment.