% Generated by roxygen2: do not edit by hand % Please edit documentation in R/update_fittedmodel.R \name{parallel_update} \alias{parallel_update} \title{Internal function to fit glmmTMB models in parallel.} \usage{ parallel_update( formula, list_tmb, n.cores = NULL, log_file = paste(tempdir(check = FALSE), "htrfit.log", sep = "/"), cl_type = "PSOCK", ... ) } \arguments{ \item{formula}{Formula for the GLMNB model.} \item{list_tmb}{List of glmmTMB objects.} \item{n.cores}{Number of cores to use for parallel processing.} \item{log_file}{File path for the log output (default : Rtmpdir/htrfit.log).} \item{cl_type}{cluster type (defautl "PSOCK"). "FORK" is recommanded for linux.} \item{...}{Additional arguments to be passed to the glmmTMB::glmmTMB function.} } \value{ A list of updated GLMNB models. } \description{ This function is used internally by \code{\link{updateParallel}} to fit glmmTMB models in parallel. } \examples{ data(iris) groups <- unique(iris$Species) group_by <- "Species" formula <- Sepal.Length ~ Sepal.Width + Petal.Length fitted_models <- fitModelParallel(formula, iris, group_by, n.cores = 1) new_formula <- Sepal.Length ~ Sepal.Width results <- parallel_update(new_formula, fitted_models, n.cores = 1) }