View source: R/heterogeneity_metrics_for_forest.r
heterogeneity_metrics_for_forest | R Documentation |
This function converts a metafor metaanalysis fit object to a string that contains the I^2 and H^2 heterogeneity statistics so that it can easily be added to a metafor forest plot.
heterogeneity_metrics_for_forest(fit)
fit |
The meta analysis fit object outputted by sced_meta_analysis() |
# calculate participant level results results <- sced_analysis(data = data) # fit meta sced_meta_fit <- sced_meta_analysis(results = results, effect_size = "ruscios_A") # forest plot metafor::forest(sced_meta_fit$model_fit, xlab = "Probability of superiority", transf = boot::inv.logit, # convert logits back to probabilities (ie Ruscio's A) mlab = heterogeneity_metrics_for_forest(sced_meta_fit$model_fit), digits = 2, addcred = TRUE, refline = 0.5)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.