From 46763edbd1c9b14cff15c53d96312a7930225704 Mon Sep 17 00:00:00 2001 From: Johannes Ranke Date: Wed, 15 Jul 2020 11:49:34 +0200 Subject: Use try() within mmkin This keeps mmkin from stopping if one of the fits fails. Instead, a try-error is assigned to the respective position in the mmkin object. --- R/mmkin.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'R') diff --git a/R/mmkin.R b/R/mmkin.R index 37c4e87d..adb9f4d0 100644 --- a/R/mmkin.R +++ b/R/mmkin.R @@ -95,7 +95,7 @@ mmkin <- function(models = c("SFO", "FOMC", "DFOP"), datasets, w <- which(fit_indices == fit_index, arr.ind = TRUE) model_index <- w[1] dataset_index <- w[2] - mkinfit(models[[model_index]], datasets[[dataset_index]], ...) + res <- try(mkinfit(models[[model_index]], datasets[[dataset_index]], ...)) } if (is.null(cluster)) { -- cgit v1.2.1