Skip to content
Prev 3060 / 5632 Next

[R-meta] catching errors in batch meta-analyses

I find the functions safely() and possibly() from the purrr package for
this sort of error handling stuff. For instance, create

safe_reitsma <- safely(mada::reitsma)

Then run

X_mada <- safe_reitsma(data=subset(X,SUBMA_num==iii),
correction.control="single", correction=0.5)

The result will always have two components, X_mada$result and X_mada$error.
Further details and examples here:
https://purrr.tidyverse.org/reference/safely.html

James

On Sun, Aug 15, 2021 at 5:57 PM Philippe Tadger <philippetadger at gmail.com>
wrote: