library(tidyverse) library(meta) library(dmetar) # Meta-analysis to calculate the prevalence of hypertension m.prop <- metaprop( event = events, # Number of events (cases of hypertension) n = population, # Study population size studlab = paste(id_article), # Study labels data = hiper, # Dataset method = "GLMM", # Estimation method (generalized linear mixed model) sm = "PLOGIT", # Effect measure using logit of the proportion fixed = FALSE, # Do not apply fixed effects model random = TRUE, # Apply random effects model method.random.ci = "HK", # Confidence interval method (Hartung-Knapp) prediction = FALSE, # Disable prediction for new studies title = "Prevalence of Hypertension" # Title of the analysis ) # Generate the forest plot for the meta-analysis forest(m.prop) # Meta-regression to evaluate the impact of the "Year_publi_categ" variable m.prop.reg <- metareg(m.prop, ~Year_publi) # Generate bubble plot to visualize the meta-regression bubble(m.prop.reg, studlab = TRUE) Year_publi <- c(2014, 2010, 2014, 2019, 2010, 1982, 2020, 1978, 2001, 2018, 2002, 2009, 2011, 2011, 2013)