Skip to content

Commit

Permalink
actually use pathfinder
Browse files Browse the repository at this point in the history
  • Loading branch information
sbfnk committed Mar 22, 2024
1 parent f7055f3 commit 3e24291
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion R/estimate_infections.R
Original file line number Diff line number Diff line change
Expand Up @@ -547,8 +547,10 @@ fit_model_approximate <- function(args, future = FALSE, id = "stan") {
} else if (inherits(stan_args$object, "CmdStanModel")) {
if (method == "vb") {
sample_func <- stan_args$object$variational

Check warning on line 549 in R/estimate_infections.R

View check run for this annotation

Codecov / codecov/patch

R/estimate_infections.R#L549

Added line #L549 was not covered by tests
} else {
} else if (method == "laplace") {
sample_func <- stan_args$object$laplace
} else {
sample_func <- stan_args$object$pathfinder
}
stan_args$object <- NULL
}
Expand Down

0 comments on commit 3e24291

Please sign in to comment.