From db9190e13af680cf6d17da7f93b41b10be5fd467 Mon Sep 17 00:00:00 2001 From: Elliot Gould Date: Mon, 4 Sep 2023 15:57:25 +1000 Subject: [PATCH] Add method for parsnip _glm model --- R/check_convergence.R | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/R/check_convergence.R b/R/check_convergence.R index f86bff381..8472b8770 100644 --- a/R/check_convergence.R +++ b/R/check_convergence.R @@ -107,3 +107,8 @@ check_convergence.glmmTMB <- function(x, ...) { # https://github.com/glmmTMB/glmmTMB/issues/275 isTRUE(x$sdr$pdHess) } + +#' @export +check_convergence._glm <- function(x, ...){ + isTRUE(x$fit$converged) +}