#Libraries

library(meta)
library(metasens)
library(readxl)
library(metafor)
library(DescTools)
library(psych)

library(tidyverse)
library(metaviz)
library(table1)
library(stargazer)

#Data

#download data and subset it
data_full <- read_xlsx("/Users/ferrec14/Documents/Meta Analysis/meta_analysis_0321.xlsx", sheet= "representatives_global_memory")
data <- subset(data_full, table1 ==1 & exclude !=1 ) 

#Tables 1

data_table1 <- subset(data_full, table1 == 1 & exclude != 1)
#labels
label(data_table1$memory_composite) <- "Memory"
label(data_table1$global_composite) <- 'Global'
label(data_table1$author) <- 'Author'
label(data_table1$year) <- 'Year '
label(data_table1$amyloid) <- 'Amyloid'
label(data_table1$tau) <- 'Tau'
label(data_table1$interaction) <- 'Interaction'
label(data_table1$addition) <- 'Addition'
label(data_table1$selected_tau_amyloid) <- 'Selected ligand'
label(data_table1$ligand) <- 'Ligand'
label(data_table1$ligand_other) <- 'Ligand other'
label(data_table1$csf) <- 'CSF'
label(data_table1$csf_other) <- 'CSF other'
label(data_table1$serum) <- 'Serum'
label(data_table1$type_study) <- 'Type study'
label(data_table1$neurodeg) <- 'Neurodegeneration'
label(data_table1$method) <- 'Method'
label(data_table1$controlled) <- 'Controlled'
label(data_table1$cov_time) <- 'Time'
label(data_table1$sex) <- 'Sex'
label(data_table1$education) <- 'Education'
label(data_table1$apoe) <- 'Apoe'
label(data_table1$covaratiate_others) <- 'Other cov'
label(data_table1$cohort_database) <- 'Cohort'
label(data_table1$age_type) <- 'Age type'
#label(data_table1$age) <- 'Age'
#label(data_table1$age_variance) <- 'Age variance'
#abel(data_table1$total_nc) <- 'Total N'
#label(data_table1$nc_pos) <- 'N positive'
#label(data_table1$nc_neg) <- 'N negative'
label(data_table1$roi_lateral_temporal) <- 'ROI temporal lateral'
label(data_table1$roi_entorhinal_hippocampus) <-
'ROI entorhinal or hipocampus'
label(data_table1$roi_lateral_parietal) <- 'ROI parietal lateral'
label(data_table1$roi_cingulate) <- 'ROI cingulate'
label(data_table1$roi_frontal) <- 'ROI frontal'
label(data_table1$roi_precuneus) <- 'ROI precuneus'
label(data_table1$roi_occipital) <- 'ROI occipital'
label(data_table1$suvr_dvr) <- 'SUVR/DVR'
#label(data_table1$type_cognitive) <- ''
label(data_table1$cross_long) <- 'CS or Longitudinal'
label(data_table1$all_r) <- 'R value'
label(data_table1$exclude) <- ''
label(data_table1$fisherz) <- 'Fisher z'
label(data_table1$weight) <- 'Weighted (n-3)'
label(data_table1$weight_se) <- 'Weigted SE'

#as factors

data_table1$memory_composite <-
as.factor(data_table1$memory_composite)
data_table1$global_composite <-
as.factor(data_table1$global_composite)
data_table1$amyloid <- as.factor(data_table1$amyloid)
data_table1$tau <- as.factor(data_table1$tau)
data_table1$interaction <- as.factor(data_table1$interaction)
data_table1$addition <- as.factor(data_table1$addition)
data_table1$selected_tau_amyloid <-
as.factor(data_table1$selected_tau_amyloid)
data_table1$type_study <- as.factor(data_table1$type_study)
data_table1$neurodeg <- as.factor(data_table1$neurodeg)
data_table1$sex <- as.factor(data_table1$sex)
data_table1$education <- as.factor(data_table1$education)
data_table1$apoe <- as.factor(data_table1$apoe)
data_table1$age_type <- as.factor(data_table1$age_type)
data_table1$roi_lateral_temporal <-
as.factor(data_table1$roi_lateral_temporal)
data_table1$roi_entorhinal_hippocampus <-
as.factor(data_table1$roi_entorhinal_hippocampus)
data_table1$roi_lateral_parietal <-
as.factor(data_table1$roi_lateral_parietal)
data_table1$roi_cingulate <- as.factor(data_table1$roi_cingulate)
data_table1$roi_frontal <- as.factor(data_table1$roi_frontal)
data_table1$roi_precuneus <- as.factor(data_table1$roi_precuneus)
data_table1$roi_occipital <- as.factor(data_table1$roi_occipital)
data_table1$suvr_dvr <- as.factor(data_table1$suvr_dvr)
data_table1$type_cognitive <- as.factor(data_table1$type_cognitive)
data_table1$cross_long <- as.factor(data_table1$cross_long)

##Table descriptive amyloid

##Table descriptive tau

##Table summary included papers

newtab <-
  data.frame(
  data_table1$author,
  data_table1$year,
  data_table1$cohort_database,
  data_table1$method,
  data_table1$cross_long,
  data_table1$cov_time,
  data_table1$controlled,
  data_table1$total_nc,
  data_table1$Global_composite,
  data_table1$Memory_composite
  )
newtab <-newtab %>% arrange(data_table1$cohort_database, desc(data_table1$total_nc), data_table1$method, data_table1$Global_composite)
  
  names(newtab)[names(newtab) == "data_table1.author"] <- "Author"
  names(newtab)[names(newtab) == "data_table1.method"] <- "Method"
  names(newtab)[names(newtab) == "data_table1.year"] <- "Year"
  names(newtab)[names(newtab) == "data_table1.cohort_database"] <- "Cohort"
  names(newtab)[names(newtab) == "data_table1.cross_long"] <- "Type of study"
  names(newtab)[names(newtab) == "data_table1.cov_time"] <- "Controlled by time of follow-up"
  names(newtab)[names(newtab) == "data_table1.controlled"] <- "Controlled"
  names(newtab)[names(newtab) == "data_table1.total_nc"] <- "N"
  names(newtab)[names(newtab) == "data_table1.Global_composite"] <- "Global"
  names(newtab)[names(newtab) == "data_table1.Memory_composite"] <- "Memory"
  
 
  kableExtra::kbl(newtab) %>%
  kableExtra::kable_paper(bootstrap_options = "striped", full_width = F)
Author Year Cohort Method Type of study Controlled by time of follow-up Controlled N Global Memory
Kawas CH 2012 90 + study Florbetapir C No No 13 0.3097950 NA
Kawas CH 2012 90 + study Florbetapir C No No 13 NA NA
Kawas CH 2012 90 + study Florbetapir C No No 13 NA -0.2974385
Kawas CH 2012 90 + study Florbetapir L Yes No 7 0.9540240 NA
Kawas CH 2012 90 + study Florbetapir L Yes No 7 NA NA
Kawas CH 2012 90 + study Florbetapir L Yes No 6 NA 0.3272785
Sperling RA; 2020 A4S Florbetapir C 0 Yes 6763 -0.0546389 NA
Sperling RA; 2020 A4S Florbetapir C 0 Yes 6763 NA -0.0546389
Doré, Vincent; 2013 ABLS PiB C 0 No 93 0.1121239 NA
Doré, Vincent; 2013 ABLS PiB L 0 No 53 0.0748669 NA
Groot C; 2021 ABLS Flortaucipir C 0 No 47 -0.3100000 NA
Groot C; 2021 ABLS Flortaucipir C 0 No 47 NA -0.2300000
Jansen WJ 2017 ABS PiB C No Yes 2908 0.0709225 NA
Jansen WJ 2017 ABS PiB C No Yes 2908 NA 0.0884409
Xiong C 2016 ACS Ab42 C No Yes 209 0.0200000 NA
Xiong C 2016 ACS Ab42 L No Yes 209 0.2200000 NA
Xiong C 2016 ACS PiB C No Yes 209 0.1500000 NA
Xiong C 2016 ACS PiB L No Yes 209 0.2700000 NA
Xiong C 2016 ACS ptau C No Yes 209 0.0600000 NA
Xiong C 2016 ACS ptau L No Yes 209 0.3300000 NA
Donohue MC 2017 ADNI Florbetapir, PiB L Yes Yes 445 0.0100000 NA
Donohue MC 2017 ADNI Florbetapir, PiB C No No 445 0.0398969 NA
Donohue MC 2017 ADNI Florbetapir, PiB L Yes Yes 445 NA 0.2400000
Moscoso A; 2021 ADNI Florbetapir, p-tau181 C Yes Yes 378 -0.3300000 NA
Moscoso A; 2021 ADNI p-tau181 L 0 Yes 378 -0.1200000 NA
Guo T; 2020 ADNI Florbetapir, Florbetaben C Yes Yes 299 0.0000000 NA
Guo T; 2020 ADNI Florbetapir, Florbetaben, Flortaucipir C Yes Yes 299 0.0000000 NA
Guo T; 2020 ADNI Flortaucipir C Yes Yes 299 0.0000000 NA
Schott JM 2010 ADNI Ab42 C No Yes 105 0.1331823 NA
Schott JM 2010 ADNI Ab42 C No Yes 105 NA -0.0303373
Diouf I; 2020 ADNI ttau/ab42 C Yes Yes 68 -0.7035720 NA
Aschenbrenner AJ 2014 ADRC Ab42 C No Yes 113 NA -0.0650000
Aschenbrenner AJ 2014 ADRC PiB C No Yes 113 NA 0.0550000
Aschenbrenner AJ 2014 ADRC ptau C No Yes 113 NA 0.0250000
Harrington KD 2018 AIBL Florbetapir, PiB, FDDNP C No No 494 0.0829341 NA
Harrington KD 2018 AIBL Florbetapir, PiB, FDDNP C No Yes 494 NA 0.1105152
Lim YY 2018 AIBL Florbetapir, PiB, FDDNP C No No 447 0.2093804 NA
Lim YY 2018 AIBL Florbetapir, PiB, FDDNP L Yes Yes 447 NA 0.1505543
Mil√†-Alom√† M; 2020 ALFA + Aβ42/40 C 0 Yes 381 -0.0500181 NA
Mil√†-Alom√† M; 2020 ALFA + Aβ42/40 L 0 Yes 381 NA 0.0000000
Milà-Alomà M; 2020 ALFA + ptau C 0 Yes 381 0.0336120 NA
Milà-Alomà M; 2020 ALFA + ptau C 0 Yes 381 NA 0.0000000
Berenguer RG 2014 Alicante Ab42 C No No 39 NA 0.3770000
Berenguer RG 2014 Alicante ab42/ptau C No No 39 NA 0.3440000
van Harten AC 2013 Amsterdam Ab42 C No No 132 0.1643990 NA
van Harten AC 2013 Amsterdam Ab42 L Yes No 132 0.8574929 NA
van Harten AC 2013 Amsterdam Ab42 C No No 132 NA 0.8516583
van Harten AC 2013 Amsterdam Ab42 L Yes No 132 NA 0.5547002
van Harten AC 2013 Amsterdam ab42/ttau C No No 132 0.0000000 NA
van Harten AC 2013 Amsterdam ab42/ttau L Yes No 132 0.8574929 NA
van Harten AC 2013 Amsterdam ab42/ttau C No No 132 NA 0.5547002
van Harten AC 2013 Amsterdam ab42/ttau L Yes No 132 NA 0.8682431
van Harten AC 2013 Amsterdam ptau L Yes No 132 0.1643990 NA
van Harten AC 2013 Amsterdam ptau C No No 132 0.4472136 NA
van Harten AC 2013 Amsterdam ptau C No No 132 NA 0.6000000
van Harten AC 2013 Amsterdam ptau L Yes No 132 NA 0.4472136
Tolboom 2009 Amsterdam FDDNP C No Yes 13 0.3900000 NA
Tolboom 2009 Amsterdam PiB C No Yes 13 0.7500000 NA
Harrison TM; 2020 BACS Flortaucepir C 0 Yes 125 0.1156070 NA
Harrison TM; 2020 BACS Flortaucepir C 0 Yes 125 NA -0.3380000
Harrison TM; 2020 BACS PiB C 0 Yes 125 0.1237862 NA
Harrison TM; 2020 BACS PiB C 0 Yes 125 NA 0.2000000
Chen X; 2021 BACS Flortaucepir L Yes Yes 124 NA -0.0217334
Chen X; 2021 BACS PiB C 0 No 124 NA 0.1455899
Chen X; 2021 BACS PiB, Flortaucepir L Yes Yes 124 NA -0.0260044
Ossenkoppele R 2013 BACS PiB C No Yes 81 -0.2292357 NA
Ossenkoppele R 2013 BACS PiB C No Yes 81 0.0572249 NA
Ossenkoppele R 2013 BACS PiB C No Yes 81 NA 0.0833677
Sierra-Rio A 2015 Barcelona ab42/ptau C No No 55 0.0475204 NA
Molinuevo JL 2014 Barcelona ab42/ptau/ttau C No Yes 38 0.1724884 NA
Molinuevo JL 2014 Barcelona ab42/ptau/ttau C No Yes 38 NA 0.0722052
Tort-Merino A; 2019 BCN Ab42 L 0 Yes 32 NA -0.0400000
Tort-Merino A; 2019 BCN ptau L 0 Yes 32 NA -0.2400000
Chen L; 2021 Biocard (JH) PiB C 0 Yes 97 0.0558103 NA
Insel PS 2019 BioFINDER ab42/ab40 C No Yes 329 0.0458154 NA
Palmqvist S 2014 BioFINDER Flutemetamol C No Yes 118 0.3200000 NA
Palmqvist S 2014 BioFINDER Flutemetamol C No Yes 118 NA 0.2800000
Bilgel M 2018 BLSA PiB L Yes No 127 0.8434402 NA
Bilgel M 2018 BLSA PiB L Yes Yes 127 NA 0.0574776
Ziontz J; 2019 BLSA Flortaucepir L Yes Yes 54 NA 0.0000000
Ziontz J; 2019 BLSA PiB L Yes Yes 54 NA 0.0034419
Resnick SM 2010 BLSA PiB L Yes Yes 51 0.0135846 NA
Resnick SM 2010 BLSA PiB L Yes Yes 51 NA 0.0163589
Radanovic M 2019 Brazil Ab42 C No Yes 54 0.2110000 NA
Radanovic M 2019 Brazil ab42/ptau181 C No Yes 54 0.2070000 NA
Radanovic M 2019 Brazil ptau181 C No Yes 54 0.2840000 NA
Stomrud E 2010 CMRU Ab42 C No Yes 37 -0.0005000 NA
Stomrud E 2010 CMRU Ab42 L No Yes 37 0.2300000 NA
Stomrud E 2010 CMRU Ab42 C No Yes 37 NA 0.1340000
Stomrud E 2010 CMRU Ab42 L No Yes 37 NA 0.4370000
Stomrud E 2010 CMRU ptau 181 C No Yes 37 -0.0320000 NA
Stomrud E 2010 CMRU ptau 181 L No Yes 37 0.0600000 NA
Stomrud E 2010 CMRU ptau 181 C No Yes 37 NA -0.1280000
Stomrud E 2010 CMRU ptau 181 L No Yes 37 NA -0.0940000
Doraiswamy PM 2014 cohort Florbetapir C No No 67 0.0693774 NA
Doraiswamy PM 2014 cohort Florbetapir L Yes Yes 67 0.1237229 NA
Doraiswamy PM 2014 cohort Florbetapir C No No 67 NA 0.2334509
Joannette M; 2020 CRIUGM PiB C 0 Yes 104 NA 0.5865151
Kristofikova Z 2014 Czech Republic. Ab42 C No No 15 0.1720000 NA
Kristofikova Z 2014 Czech Republic. ptau C No No 15 0.4450000 NA
Horn MM 2018 Dallas PiB C No Yes 195 NA 0.2500000
Franzmeier N 2018 DELCODE Florbetapir C No No 49 0.2613050 NA
Franzmeier N 2018 DELCODE Florbetapir C No Yes 49 NA 0.1203751
Visser PJ 2009 DESCRIPA ab42/ttau C No Yes 60 -0.0576322 NA
Visser PJ 2009 DESCRIPA ab42 L No Yes 58 NA 0.0449278
Visser PJ 2009 DESCRIPA ab42/ttau L No Yes 58 0.0142401 NA
Caballero MÁA; 2020 DLBS Florbetapir C 0 Yes 294 NA 0.1373950
Farrell ME 2017 DLBS Florbetapir L Yes No 123 0.7180338 NA
Farrell ME 2017 DLBS Florbetapir L Yes No 123 NA 0.8046629
Song Z 2016 DLBS Florbetapir C No No 82 0.1225236 NA
Song Z 2016 DLBS Florbetapir C No No 82 NA 0.1287696
Lu K 2019 DRC-UK Florbetapir C No Yes 502 0.2050000 NA
Lu K 2019 DRC-UK Florbetapir C Yes Yes 502 NA 0.1200000
Bos I; 2019 EMIF ab42/40, ttau C No Yes 140 0.5397881 NA
Gangishetti U 2018 Emory, Penn, Washu Florbetapir C No No 44 0.1008711 NA
Konijnenberg E 2019 European Information Framework for AD-PreclinAD Flutemetamol C No Yes 196 NA 0.0775520
Konijnenberg E 2019 European Information Framework for AD-PreclinAD ab42/ab40 C No Yes 126 NA 0.0345742
Kemppainen N 2017 FINGER PiB C No Yes 48 0.1034905 NA
Kemppainen N 2017 FINGER PiB C No Yes 48 NA 0.0313408
Haapalinna F 2018 Finland Ab42 C No No 57 NA 0.2860000
Martikainen IK 2018 Finnish Geriatric Intervention Study PiB C No Yes 40 0.0304178 NA
Martikainen IK 2018 Finnish Geriatric Intervention Study PiB C No Yes 40 NA -0.1323262
Kang JM 2017 Gachon, Korea THK5351 C No Yes 43 NA 0.0677500
Cho H; 2019 Gangnam Florbetaben L 0 No 52 -0.0209696 NA
Cho H; 2019 Gangnam Florbetaben C 0 No 52 0.0185606 NA
Cho H; 2019 Gangnam Florbetaben C 0 No 52 NA 0.0514524
Cho H; 2019 Gangnam Florbetaben L 0 No 52 NA 0.0468836
Ecay-Torres M 2018 GAP Ab42 C No Yes 238 0.0010000 NA
Zhao Y 2017 GEM PiB C No No 175 NA 0.0819069
Rådestig MA; 2021 Gothenburg Ab42 C 0 No 259 0.0311846 NA
Rådestig MA; 2021 Gothenburg Ab42 C 0 No 259 NA 0.3169288
Rådestig MA; 2021 Gothenburg ptau C 0 No 259 NA -0.0027847
Hanseeuw BJ 2017 HABS PiB C No No 277 0.1317225 NA
Hanseeuw BJ 2017 HABS PiB L No No 277 0.1777283 NA
Hanseeuw BJ 2017 HABS PiB L No No 277 NA -0.0411176
Hanseeuw BJ 2017 HABS PiB C No No 277 NA 0.0337453
Jacobs HIL 2018 HABS PiB C No Yes 256 0.0759581 NA
Jacobs HIL 2018 HABS PiB C No Yes 256 NA -0.0011623
Chhatwal JP; 2020 HABS NT1 C Yes Yes 112 0.0000000 NA
Chhatwal JP; 2020 HABS NT1 L Yes Yes 112 0.0000000 NA
Chhatwal JP; 2020 HABS PiB L Yes Yes 112 0.0000000 NA
Chhatwal JP; 2020 HABS PiB L Yes Yes 112 0.0000000 NA
Hanseeuw BJ; 2019 HBS PiB, Flortaucepir NA Yes Yes 60 0.0000000 NA
Yaffe K 2011 Healthy ABC ab42/ab40 L No No 659 -0.0800631 NA
Yaffe K 2011 Healthy ABC ab42/ab40 C No No 659 0.0198521 NA
Yaffe K 2011 Healthy ABC Ab42 L No No 658 -0.1112537 NA
Yaffe K 2011 Healthy ABC Ab42 C No No 658 -0.0323689 NA
Mok VC 2016 Hong Kong PiB C No Yes 75 0.1400470 NA
Mok VC 2016 Hong Kong PiB L No Yes 53 0.0726713 NA
Mok VC 2016 Hong Kong PiB L No Yes 53 0.1850980 NA
Mok VC 2016 Hong Kong PiB L No Yes 53 0.3220456 NA
Hamelin L 2018 IMABio3 PiB C No No 17 0.1396219 NA
Hamelin L 2018 IMABio3 PiB L No No 17 0.1672821 NA
Hamelin L 2018 IMABio3 PiB L No No 17 NA 0.2762891
Besson FL 2015 IMAP 0 C No No 54 -0.0504891 NA
Besson FL 2015 IMAP 0 C No No 54 NA -0.1110823
Hoscheidt SM 2016 IMPACT ab42/ab40/ptau/ttau C No Yes 70 NA 0.0964365
Teipel SJ 2017 INSIGHT Florbetapir C No Yes 318 0.1100000 NA
Dubois B 2018 INSIGHT Florbetapir C No Yes 318 0.1213773 NA
Teipel SJ 2017 INSIGHT Florbetapir C No Yes 318 NA 0.1220000
Dubois B 2018 INSIGHT Florbetapir C No Yes 318 NA 0.0090362
Tardif CL 2017 INTREPAD Ab42 C No No 46 -0.1107440 NA
Tardif CL 2017 INTREPAD ttau C No No 46 0.3570145 NA
Rosenberg PB 2013 John Hopkns Florbetapir C No No 15 0.1650000 NA
Rosenberg PB 2013 John Hopkns Florbetapir C No No 15 NA 0.1500000
Chatterjee P 2019 KARVIAH Florbetaben C No No 100 -0.1245904 NA
Leahey TM 2008 Kent USA Ab40 C No Yes 35 0.3400000 NA
Bos I; 2019 Knight Ab42 C 0 Yes 433 0.1145347 NA
Bos I; 2019 Knight ttau C 0 Yes 433 0.0742767 NA
Roe CM 2013 Knight ab42 L No Yes 430 0.0678207 NA
Roe CM 2013 Knight ptau181 L No Yes 430 0.0548775 NA
Roe CM 2013 Knight ptau181/ab42 L No Yes 430 0.0926467 NA
Schindler SE 2017 Knight Ab42 L Yes Yes 233 0.0405000 NA
Schindler SE 2017 Knight Ab42 C Yes Yes 233 0.0755000 NA
Schindler SE 2017 Knight Ab42 C Yes Yes 233 NA 0.0695833
Schindler SE 2017 Knight Ab42 L Yes Yes 233 NA 0.0110000
Schindler SE 2017 Knight ptau C Yes Yes 233 0.0025000 NA
Schindler SE 2017 Knight ptau L Yes Yes 233 0.0135000 NA
Schindler SE 2017 Knight ptau C Yes Yes 233 NA 0.0282500
Schindler SE 2017 Knight ptau L Yes Yes 233 NA 0.0175000
Schindler SE 2017 Knight ptau/ab42 L Yes Yes 233 0.0385000 NA
Schindler SE 2017 Knight ptau/ab42 C Yes Yes 233 0.0695000 NA
Schindler SE 2017 Knight ptau/ab42 C Yes Yes 233 NA 0.0950833
Schindler SE 2017 Knight ptau/ab42 L Yes Yes 233 NA 0.0210000
Storandt M 2009 Knight PiB L Yes Yes 135 0.0041069 NA
Storandt M 2009 Knight PiB C No No 135 0.1209122 NA
Storandt M 2009 Knight PiB L Yes Yes 135 NA 0.0041069
Moon YS 2011 Korean ab42 C No Yes 123 0.2500000 NA
Adamczuk K 2014 Leuven Flutemetamol C No Yes 56 0.2271847 NA
Adamczuk K 2014 Leuven Flutemetamol C No Yes 56 NA 0.2150714
Janelidze S 2018 Mälmo Diet Cancer Study +BioFINDER ab42/ab40 C No Yes 508 0.1161625 NA
Lilamand M 2019 MAPT Florbetapir C No No 269 0.1056808 NA
Lilamand M 2019 MAPT Florbetapir L Yes Yes 269 0.4713930 NA
Lilamand M 2019 MAPT Florbetapir L Yes Yes 269 NA 0.1433694
Roberts RO 2018 MCSA PiB L No Yes 1492 -0.0367629 NA
Roberts RO 2018 MCSA PiB C No No 1492 0.2087571 NA
Roberts RO 2018 MCSA PiB L No Yes 1492 NA -0.0385758
Roberts RO 2018 MCSA PiB C No No 1492 NA 0.1569886
Mielke MM 2012 MCSA PiB C No Yes 483 -0.0270166 NA
Mielke MM 2012 MCSA PiB C No Yes 483 NA -0.0220700
Mielke MM 2017 MCSA PiB L Yes Yes 115 0.0116555 NA
Mielke MM 2017 MCSA PiB L Yes Yes 115 NA 0.0058281
Nakamura A 2018 MULNIAD PiB C No Yes 38 -0.0189523 NA
Nakamura A 2018 MULNIAD PiB C No Yes 38 NA -0.0141493
Lafirdeen ASM 2019 Multicenter France ab42 C No Yes 3562 0.2219107 NA
Lafirdeen ASM 2019 Multicenter France ptau/ttau C No Yes 3562 0.1733867 NA
Snitz BE; 2020 MYHAT‐NI Florbetapir C 0 Yes 118 -0.0300000 NA
Snitz BE; 2020 MYHAT‐NI Florbetapir C 0 Yes 118 NA 0.0200000
Snitz BE; 2020 MYHAT‐NI NA C 0 Yes 118 -0.1600000 NA
Snitz BE; 2020 MYHAT‐NI NA C 0 Yes 118 NA 0.0200000
Pomara N 2005 Nathan Kline Ab42 L No No 34 0.4100000 NA
Sala-Llonch R 2017 Norway Ab42 C No No 89 -0.0467196 NA
Sala-Llonch R 2017 Norway Ab42 L No No 89 0.1102283 NA
Sala-Llonch R 2017 Norway Ab42 C No No 89 NA -0.0524737
Harrington MG 2013 Pasadena ab42/ttau C No No 46 NA -0.0663486
Meng Y 2015 Peking APL1b28 C No No 35 0.0250556 NA
Nebes RD 2013 PITT PiB C No Yes 71 NA 0.1295316
Aizenstein HJ 2008 PITT PiB C No No 38 -0.1215034 NA
Aizenstein HJ 2008 PITT PiB C No No 34 NA -0.3791941
Jiao F; 2020 PLA Beijing PiB, ab42 C 0 No 57 0.0325000 NA
Jiao F; 2020 PLA Beijing PiB, ab42, ttau C 0 No 57 -0.1020000 NA
Jiao F; 2020 PLA Beijing ttau C 0 No 57 -0.1160000 NA
McMillan CT 2016 PPMI Ab42 C No Yes 174 NA -0.3465076
McMillan CT 2016 PPMI ab42/ptau/ttau C No Yes 174 0.3727037 NA
Lim YY 2015 Rhode Island Florbetapir C No No 63 -0.0452078 NA
Lim YY 2015 Rhode Island Florbetapir L No No 63 0.0606041 NA
Lim YY 2015 Rhode Island Florbetapir C No No 63 NA 0.1836993
Liguori C 2017 Rome Ab42 C No No 50 NA 0.7250000
Ebenau JL; 2020 science PiB, Florbetaben, Florbetapir, Flutematamol, ab42, ptau, ttau C 0 Yes 693 0.0000000 NA
Timmers T 2019 SCIENCe Florbetapir L No Yes 107 0.4860464 NA
Timmers T 2019 SCIENCe Florbetapir C No Yes 107 0.7456244 NA
Timmers T 2019 SCIENCe Florbetapir C No Yes 107 NA 0.6711077
Timmers T 2019 SCIENCe Florbetapir L No Yes 107 NA 0.3085927
Llado-Saz S 2015 Seville Florbetapir C No Yes 120 NA 0.0285706
Hahn A; 2020 south korea Florbetapir, Florbetaben, Flutemetamol C 0 Yes 423 0.0000000 NA
Hahn A; 2020 south korea Florbetapir, Florbetaben, Flutemetamol C 0 Yes 423 NA 0.0000000
Huang KL 2018 Taiwan Florbetapir C No Yes 11 NA -0.5600000
Karikari TK; 2020 TRIAD Florbetapir, ab42, p-tau181 C 0 Yes 85 0.0000000 NA
Karikari TK; 2020 TRIAD Florbetapir, ab42, p-tau182 L 0 Yes 85 0.0000000 NA
Han JW; 2020 UCD ADRC PiB C 0 Yes 154 NA -0.0012607
Han JW; 2020 UCD ADRC PiB L Yes Yes 154 NA -0.0130733
Mueller SG 2018 UCSF Florbetapir C No No 51 0.1524001 NA
Mueller SG 2018 UCSF Florbetapir C No No 51 NA 0.0639220
Song Z 2015 UCSF Florbetapir C No Yes 50 0.0200000 NA
Song Z 2015 UCSF Florbetapir C No Yes 50 NA 0.0040000
Hammers DB 2017 Utah Flutemetamol C No Yes 27 0.1912685 NA
Hammers DB 2017 Utah Flutemetamol C No Yes 27 NA 0.3002590
Gu 2012 WHICAP Ab42 C No Yes 813 NA 0.0670742
Cosentino SA 2010 WHICAP Ab42 C No Yes 481 0.0200000 NA
Cosentino SA 2010 WHICAP Ab42 C Yes Yes 481 NA 0.0233333
Cosentino SA 2010 WHICAP Ab43 L No Yes 481 0.0100000 NA
Casaletto KB 2017 Wisconsin ADRC Ab42 C No No 132 NA 0.0200000
Casaletto KB 2017 Wisconsin ADRC ptau C No No 132 NA -0.1400000
Mecca AP 2017 Yale PiB C No Yes 45 NA 0.1270000
van Bergen JMG 2018 zurich Flutemetamol C No Yes 116 -0.0447848 NA
  # stargazer(
  #   newtab,
  #   summary = FALSE,
  #   single.row = TRUE,
  #   no.space = TRUE,
  #   digits = 2,
  #   column.sep.width = "1pt",
  #   font.size = "small", 
  #   type = 'text',
  #   out= "summary.text"
  #   )

#Meta analysis ##Grouping by cognitive domain, tracer, time of analysis

#random-effects-model for r values
#data_global <- subset(data, global_composite ==1)
data$memory_composite <- factor(data$memory_composite,
                                levels = c(0, 1),
                                labels = c("", "Memory"))
data$global_composite <- factor(data$global_composite,
                                levels = c(0, 1),
                                labels = c("", "Global"))
data$cross_long <- factor(data$cross_long,
                          levels = c("C", "L"),
                          labels = c("Baseline", "Followup"))
data$amyloid <- factor(data$amyloid,
                       levels = c(0, 1),
                       labels = c("", "Amyloid "))
data$tau <- factor(data$tau,
                   levels = c(0, 1),
                   labels = c("", "Tau"))
data$interaction <- factor(data$interaction,
                           levels = c(0, 1),
                           labels = c("", "Interaction"))
first <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data,
  n = data$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR",
 
  #The summary measure we want to calculate- fisher z
  byvar = paste(
    memory_composite,
    global_composite,
    cross_long,
    amyloid,
    tau
    
  ),
  #grouping variable
  print.byvar = gs("print.byvar")
) #print grouping variable

summary(first, digits = 2, pval=TRUE)
## Number of studies combined: k = 255
## 
##                         COR            95%-CI    t  p-value
## Random effects model 0.1339 [ 0.0975; 0.1700] 7.19 < 0.0001
## Prediction interval         [-0.4041; 0.6031]              
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0814 [0.0608; 0.0950]; tau = 0.2854 [0.2465; 0.3083]
##  I^2 = 90.9% [90.0%; 91.7%]; H = 3.32 [3.17; 3.47]
## 
## Test of heterogeneity:
##        Q d.f. p-value
##  2661.15  242       0
## 
## Results for subgroups (random effects model):
##                                         k    COR            95%-CI  tau^2
## byvar = Memory  Baseline Amyloid       56 0.1286 [ 0.0574; 0.1986] 0.0626
## byvar = Memory  Baseline Amyloid  Tau   9 0.1332 [-0.0867; 0.3407] 0.0667
## byvar =  Global Baseline Amyloid       69 0.0940 [ 0.0547; 0.1329] 0.0216
## byvar =  Global Followup Amyloid       30 0.2626 [ 0.1139; 0.3998] 0.1630
## byvar =  Global Baseline Amyloid  Tau  15 0.0343 [-0.1567; 0.2229] 0.1083
## byvar =  Global Baseline  Tau          17 0.0917 [-0.0192; 0.2004] 0.0391
## byvar = Memory  Followup Amyloid       20 0.1511 [ 0.0167; 0.2801] 0.0706
## byvar =  Global Followup  Tau           8 0.0823 [-0.0507; 0.2125] 0.0202
## byvar =  Global Followup Amyloid  Tau   6 0.2812 [-0.2770; 0.6975] 0.3010
## byvar = Memory  Baseline  Tau          11 0.0036 [-0.1745; 0.1814] 0.0612
## byvar = Memory  Followup  Tau           5 0.1256 [-0.2313; 0.4527] 0.0726
## byvar = Memory  Followup Amyloid  Tau   5 0.2687 [-0.4273; 0.7647] 0.3364
## byvar =   Followup Amyloid              2 0.8739 [-1.0000; 1.0000] 1.5368
## byvar =   Baseline Amyloid              1 0.1837 [-0.4086; 0.6672]     --
## byvar =  Global NA Amyloid  Tau         1     NA                       --
##                                          tau      Q   I^2
## byvar = Memory  Baseline Amyloid      0.2501 502.72 89.1%
## byvar = Memory  Baseline Amyloid  Tau 0.2583  77.68 89.7%
## byvar =  Global Baseline Amyloid      0.1469 403.15 83.6%
## byvar =  Global Followup Amyloid      0.4038 602.04 95.3%
## byvar =  Global Baseline Amyloid  Tau 0.3291 178.93 92.7%
## byvar =  Global Baseline  Tau         0.1977  60.51 78.5%
## byvar = Memory  Followup Amyloid      0.2657 220.70 91.4%
## byvar =  Global Followup  Tau         0.1421  30.61 83.7%
## byvar =  Global Followup Amyloid  Tau 0.5486 167.60 97.6%
## byvar = Memory  Baseline  Tau         0.2475  82.64 87.9%
## byvar = Memory  Followup  Tau         0.2694  22.72 86.8%
## byvar = Memory  Followup Amyloid  Tau 0.5800 179.29 97.8%
## byvar =   Followup Amyloid            1.2397  12.73 92.1%
## byvar =   Baseline Amyloid                --   0.00    --
## byvar =  Global NA Amyloid  Tau           --     --    --
## 
## Test for subgroup differences (random effects model):
##                      Q d.f. p-value
## Between groups   11.44   14  0.6515
## 
## Prediction intervals for subgroups:
##                                                  95%-PI
## byvar = Memory  Baseline Amyloid      [-0.3603; 0.5621]
## byvar = Memory  Baseline Amyloid  Tau [-0.4757; 0.6558]
## byvar =  Global Baseline Amyloid      [-0.1990; 0.3715]
## byvar =  Global Followup Amyloid      [-0.5172; 0.8042]
## byvar =  Global Baseline Amyloid  Tau [-0.6060; 0.6477]
## byvar =  Global Baseline  Tau         [-0.3311; 0.4838]
## byvar = Memory  Followup Amyloid      [-0.3989; 0.6211]
## byvar =  Global Followup  Tau         [-0.2836; 0.4274]
## byvar =  Global Followup Amyloid  Tau [-0.8753; 0.9590]
## byvar = Memory  Baseline  Tau         [-0.5265; 0.5316]
## byvar = Memory  Followup  Tau         [-0.6784; 0.7927]
## byvar = Memory  Followup Amyloid  Tau [-0.9416; 0.9802]
## byvar =   Followup Amyloid                             
## byvar =   Baseline Amyloid                             
## byvar =  Global NA Amyloid  Tau                        
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

##Forest plot

  forest(
  first,
  print.I2.ci = TRUE,
  digits.sd = 2,
  layout = "subgroup",
  #layout = "subgroup",
  squaresize = 0.8,
  plotwidth = unit(8, "cm"),
  fontsize = 5,
  addspace = FALSE,
  xlab = "Fisher z",
  calcwidth.hetstat = TRUE
)

#option 1 -all studies
# fun <- trimfill(first)
# funnel(
#   fun,
#   pch = ifelse(fun$trimfill, 1, 16),
#   level = 0.9,
#   comb.random = FALSE
# )
# 
# funnel(first, 
#        main = "Standard Error")
# funnel(first, 
#        yaxis = "invvar")
# funnel(first,
#        yaxis = "size",
#        main = "Sampling size",
#        title = "hsjs")

#Memory ##Amyloid

###Memory amyloid baseline

data <- subset(data_full, table1 == 1 & exclude != 1)
data_memory_amyloid <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$amyloid == "1" & data$tau != "1" & data$cross_long == "C" )
MA <- metacor(
  as.numeric(all_r),
  #column with r values
  data = data_memory_amyloid,
  n = data_memory_amyloid$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
)

summary(MA, digits = 2, pval=TRUE)
## Number of studies combined: k = 56
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.1286 [ 0.0574; 0.1986] 3.61  0.0007
## Prediction interval         [-0.3603; 0.5621]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0626 [0.0379; 0.0980]; tau = 0.2501 [0.1948; 0.3131]
##  I^2 = 89.1% [86.6%; 91.1%]; H = 3.02 [2.73; 3.35]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  502.72   55 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MA,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MA)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept      95% CI     t           p
##      1.545 0.44 - 2.65 2.732 0.008479106
## 
## Eggers' test indicates the presence of funnel plot asymmetry.

Timmers T doi: 10.1016/j.pdpdt.2019.04.022 , Amsterdam, 107 NC , Florbetepan - checked Merrill DA doi: 10.3233/JAD-121903, 75 NC, FRS, FDDNP - checked Liguori doi: 10.1093/sleep/zsx011, 50 NC with, 35 with obstructuve sleep apnea, CSF ab42 - checked van Harten

####Memory amyloid baseline - no outliers

data <- subset(data_full, table1 == 1 &  exclude != 1)
data_memory_amyloid <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$amyloid == "1" & data$tau != "1" & data$cross_long == "C" & data$outliers == "0")
MA_out <- metacor(
  as.numeric(all_r),
  #column with r values
  data = data_memory_amyloid,
  n = data_memory_amyloid$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
)

summary(MA_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 52
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0852 [ 0.0441; 0.1260] 4.15  0.0001
## Prediction interval         [-0.1850; 0.3434]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0180 [0.0052; 0.0251]; tau = 0.1341 [0.0720; 0.1586]
##  I^2 = 76.3% [69.1%; 81.8%]; H = 2.05 [1.80; 2.34]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  214.83   51 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MA_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MA_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept      95% CI     t          p
##      1.006 0.22 - 1.79 2.501 0.01571119
## 
## Eggers' test indicates the presence of funnel plot asymmetry.

###Memory amyloid longitudinal

data <- subset(data_full, table1 == 1 & exclude != 1)
data_memory_amyloidL <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$amyloid == "1" & data$tau != "1" & data$cross_long == "L")
MAL <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_amyloidL,
  n = data_memory_amyloidL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(MAL, digits = 2, pval=TRUE)
## Number of studies combined: k = 20
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.1511 [ 0.0167; 0.2801] 2.35  0.0297
## Prediction interval         [-0.3989; 0.6211]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0706 [0.0368; 0.1597]; tau = 0.2657 [0.1919; 0.3996]
##  I^2 = 91.4% [88.1%; 93.8%]; H = 3.41 [2.90; 4.00]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  220.70   19 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MAL,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MAL)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      1.946 -0.85 - 4.74 1.365 0.1890963
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

Farrell, doi: 10.1001/jamaneurol.2017.0892, 123 NC, florbetapir) van Harten

####Memory amyloid longitudinal - no outliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_memory_amyloidL <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$amyloid == "1" & data$tau != "1" & data$cross_long == "L" & data$outliers =="0")
MAL_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_amyloidL,
  n = data_memory_amyloidL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(MAL_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 16
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0487 [-0.0032; 0.1003] 2.00  0.0641
## Prediction interval         [-0.1136; 0.2085]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0052 [0.0009; 0.0136]; tau = 0.0719 [0.0295; 0.1166]
##  I^2 = 63.4% [37.3%; 78.6%]; H = 1.65 [1.26; 2.16]
## 
## Test of heterogeneity:
##      Q d.f. p-value
##  40.94   15  0.0003
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MAL_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MAL_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      0.483 -1.14 - 2.11 0.581 0.5701537
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

##Amyloid and tau ###Memory amyloid and tau baseline

data <- subset(data_full, table1 == 1 & exclude != 1)
data_memory_tau <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$tau == "1" & data$amyloid == "1" & data$cross_long == "C")

MT <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_tau ,
  n = data_memory_tau $total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(MT, digits = 2, pval=TRUE)
## Number of studies combined: k = 9
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.1332 [-0.0867; 0.3407] 1.40  0.1994
## Prediction interval         [-0.4757; 0.6558]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0667 [0.0256; 0.2697]; tau = 0.2583 [0.1600; 0.5193]
##  I^2 = 89.7% [82.7%; 93.9%]; H = 3.12 [2.40; 4.04]
## 
## Test of heterogeneity:
##      Q d.f.  p-value
##  77.68    8 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MT,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MT)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      1.629 -4.69 - 7.94 0.506 0.6285625
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

####Memory amyloid and tau baseline - no outliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_memory_tau <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$tau == "1" & data$amyloid == "1" & data$cross_long == "C" & data$outliers =="0")

MT_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_tau ,
  n = data_memory_tau $total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
)

summary(MT_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 7
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.1302 [ 0.0123; 0.2445] 2.70  0.0356
## Prediction interval         [-0.1396; 0.3820]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0088 [0.0000; 0.0757]; tau = 0.0938 [0.0000; 0.2752]
##  I^2 = 0.0% [0.0%; 67.8%]; H = 1.00 [1.00; 1.76]
## 
## Test of heterogeneity:
##     Q d.f. p-value
##  5.44    6  0.4892
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MT_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MT_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      0.602 -1.52 - 2.73 0.556 0.6020448
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

McMillan - Parkisnons

###Memory amyloid tau longitudinal

data <- subset(data_full, table1 == 1 &  exclude != 1) 
data_memory_tauL <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$tau == "1" & data$amyloid == "1" & data$cross_long == "L")

MTL <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_tauL ,
  n = data_memory_tauL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(MTL, digits = 2, pval=TRUE)
## Number of studies combined: k = 5
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.2687 [-0.4273; 0.7647] 1.04  0.3551
## Prediction interval         [-0.9416; 0.9802]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.3364 [0.1162; 2.8508]; tau = 0.5800 [0.3409; 1.6884]
##  I^2 = 97.8% [96.5%; 98.6%]; H = 6.69 [5.33; 8.42]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  179.29    4 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MTL,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MTL)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept        95% CI     t        p
##      1.684 -29.5 - 32.86 0.106 0.922387
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

####Memory amyloid tau longitudinal - no outliers

data <- subset(data_full, table1 == 1 &  exclude != 1) 
data_memory_tauL <-
  subset(data, table1== "1" & data$memory_composite == "1" & data$tau == "1" & data$amyloid == "1" & data$cross_long == "L"& data$outliers =="0")

MTL_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_memory_tauL ,
  n = data_memory_tauL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(MTL_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 4
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0093 [-0.0314; 0.0499] 0.72  0.5211
## Prediction interval         [-0.0539; 0.0723]             
## 
## Quantifying heterogeneity:
##  tau^2 < 0.0001 [0.0000; 0.0015]; tau = 0.0072 [0.0000; 0.0393]
##  I^2 = 0.0%; H = 1.00
## 
## Test of heterogeneity:
##     Q d.f. p-value
##  0.25    3  0.9685
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 MTL_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = MTL_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      0.075 -1.36 - 1.51 0.102 0.9282354
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

#Global ##Amyloid ###Global amyloid baseline

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_amyloid <-
  subset(data, table1== "1" & data$global_composite == "1" & data$amyloid == "1" & data$tau != "0" & data$cross_long == "C")

GA <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_amyloid,
  n = data_global_amyloid$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GA, digits = 2, pval=TRUE)
## Number of studies combined: k = 15
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0343 [-0.1567; 0.2229] 0.38  0.7074
## Prediction interval         [-0.6060; 0.6477]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.1083 [0.0513; 0.2993]; tau = 0.3291 [0.2264; 0.5471]
##  I^2 = 92.7% [89.5%; 95.0%]; H = 3.71 [3.08; 4.46]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  178.93   13 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GA,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GA)      
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      1.071 -3.28 - 5.42 0.483 0.6379013
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

Timmers T doi: 10.1016/j.pdpdt.2019.04.022 , Amsterdam, 107 NC , Florbetepan - checked Merrill DA doi: 10.3233/JAD-121903, 75 NC, FRS, FDDNP - checked Roberts, Tolboom, 9 NC individuals

####Global amyloid baseline - no outliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_amyloid <-
  subset(data, table1== "1" & data$global_composite == "1" & data$amyloid == "1" & data$tau != "0" & data$cross_long == "C" & data$outliers =="0")

GA_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_amyloid,
  n = data_global_amyloid$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GA_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 13
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0055 [-0.2093; 0.2199] 0.06  0.9568
## Prediction interval         [-0.6517; 0.6580]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.1168 [0.0524; 0.3600]; tau = 0.3417 [0.2289; 0.6000]
##  I^2 = 92.7% [89.1%; 95.1%]; H = 3.70 [3.03; 4.53]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  150.79   11 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GA_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GA_out)      
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##       0.95 -3.46 - 5.35 0.423 0.6815968
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

###Global amyloid longitudinal

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_amyloidL <-
  subset(data, table1== "1" & data$global_composite == "1" & data$amyloid == "1" & data$tau != "0" & data$cross_long == "L")

GAL <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_amyloidL,
  n = data_global_amyloidL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
  #The summary 
) #print grouping variable

summary(GAL, digits = 2, pval=TRUE)
## Number of studies combined: k = 6
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.2812 [-0.2770; 0.6975] 1.30  0.2517
## Prediction interval         [-0.8753; 0.9590]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.3010 [0.1035; 2.5583]; tau = 0.5486 [0.3217; 1.5995]
##  I^2 = 97.6% [96.2%; 98.5%]; H = 6.47 [5.12; 8.18]
## 
## Test of heterogeneity:
##       Q d.f.  p-value
##  167.60    4 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GAL,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GAL)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept         95% CI     t         p
##      4.664 -14.54 - 23.87 0.476 0.6665892
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

Kawas, 13 NC Farrell, doi: 10.1001/jamaneurol.2017.0892, 123 NC, florbetapir) Timmers T doi: 10.1016/j.pdpdt.2019.04.022 , Amsterdam, 107 NC , Florbetepan - checked Lilamnad van Harten Bilgel, doi: 10.1093/brain/awy150, 171 NC BLSA, CVR thresholdwas 1.062 which is the lowest for DVR taht we have.

####Global amyloid longitudinal - no outliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_amyloidL <-
  subset(data, table1== "1" & data$global_composite == "1" & data$amyloid == "1" & data$tau != "0" & data$cross_long == "L" & data$outliers ==0)

GAL_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_amyloidL,
  n = data_global_amyloidL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) #print grouping variable

summary(GAL_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 5
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0602 [ 0.0131; 0.1071] 3.55  0.0239
## Prediction interval         [-0.0145; 0.1343]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0003 [0.0000; 0.0144]; tau = 0.0162 [0.0000; 0.1201]
##  I^2 = 0.0% [0.0%; 51.3%]; H = 1.00 [1.00; 1.43]
## 
## Test of heterogeneity:
##     Q d.f. p-value
##  0.94    3  0.8148
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GAL_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GAL_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept        95% CI      t         p
##     -1.187 -2.21 - -0.16 -2.276 0.1505914
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

##Amyloid and tau ###Global amyloid tau baseline

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_tau <-
  subset(data, table1== "1" & data$global_composite == "1" & data$tau == "1" & data$amyloid != "1" & data$cross_long == "C")


GT <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_tau,
  n = data_global_tau$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GT, digits = 2, pval=TRUE)
## Number of studies combined: k = 17
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0917 [-0.0192; 0.2004] 1.75  0.0985
## Prediction interval         [-0.3311; 0.4838]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0391 [0.0112; 0.1206]; tau = 0.1977 [0.1059; 0.3473]
##  I^2 = 78.5% [64.5%; 87.0%]; H = 2.16 [1.68; 2.77]
## 
## Test of heterogeneity:
##      Q d.f.  p-value
##  60.51   13 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GT,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GT)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI      t         p
##     -0.937 -2.56 - 0.69 -1.132 0.2799272
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

van harten

####Global amyloid tau baseline - no outliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_tau <-
  subset(data, table1== "1" & data$global_composite == "1" & data$tau == "1" & data$amyloid != "1" & data$cross_long == "C" & data$outliers =="0")


GT_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_tau,
  n = data_global_tau$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GT_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 15
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0441 [-0.0620; 0.1492] 0.89  0.3883
## Prediction interval         [-0.3364; 0.4122]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0308 [0.0013; 0.1141]; tau = 0.1756 [0.0366; 0.3377]
##  I^2 = 53.9% [11.4%; 76.0%]; H = 1.47 [1.06; 2.04]
## 
## Test of heterogeneity:
##      Q d.f. p-value
##  23.85   11  0.0134
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GT_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GT_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      0.231 -1.72 - 2.18 0.233 0.8208065
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

###Global amyloid tau longitudinal

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_tauL <-
  subset(data, table1== "1" & data$global_composite == "1" & data$tau == "1" & data$amyloid != "1" & data$cross_long == "L")


GTL <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_tauL,
  n = data_global_tauL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GTL, digits = 2, pval=TRUE)
## Number of studies combined: k = 8
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0823 [-0.0507; 0.2125] 1.46  0.1865
## Prediction interval         [-0.2836; 0.4274]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0202 [0.0054; 0.1423]; tau = 0.1421 [0.0735; 0.3773]
##  I^2 = 83.7% [65.9%; 92.2%]; H = 2.47 [1.71; 3.58]
## 
## Test of heterogeneity:
##      Q d.f.  p-value
##  30.61    5 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GTL,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GTL)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept       95% CI     t         p
##      2.367 -4.06 - 8.79 0.722 0.5102399
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.

Xiong

####Global amyloid tau longitudinal - no ouliers

data <- subset(data_full, table1 == 1 & exclude != 1)
data_global_tauL <-
  subset(data, table1== "1" & data$global_composite == "1" & data$tau == "1" & data$amyloid != "1" & data$cross_long == "L" & data$outliers=="0")


GTL_out <- metacor(
  as.numeric(all_r),
  #column with r values
  #pooled_se, #this tells R to use the seTE column to retrieve the standard error for each study
  data = data_global_tauL,
  n = data_global_tauL$total_nc,
  #sample sizes
  studlab = paste(author),
  # labels for each study
  comb.fixed = FALSE,
  #Whether to use a fixed-effects model
  comb.random = TRUE,
  #Whether to use a random-effects model
  method.tau = "SJ",
  #Which estimator to use for the between-study variance
  hakn = TRUE,
  #Which estimator to use for the between-study variance
  prediction = TRUE,
  #Whether to print a prediction interval for the effect of future studies based on present evidence
  sm = "ZCOR"
) 

summary(GTL_out, digits = 2, pval=TRUE)
## Number of studies combined: k = 7
## 
##                         COR            95%-CI    t p-value
## Random effects model 0.0672 [-0.0896; 0.2208] 1.05  0.3349
## Prediction interval         [-0.3499; 0.4621]             
## 
## Quantifying heterogeneity:
##  tau^2 = 0.0242 [0.0062; 0.2317]; tau = 0.1556 [0.0787; 0.4814]
##  I^2 = 86.1% [69.7%; 93.7%]; H = 2.68 [1.82; 3.97]
## 
## Test of heterogeneity:
##      Q d.f.  p-value
##  28.82    4 < 0.0001
## 
## Details on meta-analytical method:
## - Inverse variance method
## - Sidik-Jonkman estimator for tau^2
## - Q-profile method for confidence interval of tau^2 and tau
## - Hartung-Knapp adjustment for random effects model
## - Fisher's z transformation of correlations

####Funnel

funnel(
 GTL_out,
  yaxis= "se",
 legend = TRUE,
 main = "Standard Error",
 studlab = TRUE,
 xlim = c(-1,1),
 level=0.95, contour=c(0.9, 0.95, 0.99))$col.contour

## [1] "#808080" "#B3B3B3" "#E6E6E6"
dmetar::eggers.test(x = GTL_out)
## Eggers' test of the intercept 
## ============================= 
## 
##  intercept        95% CI     t         p
##      2.017 -5.98 - 10.02 0.494 0.6552297
## 
## Eggers' test does not indicate the presence of funnel plot asymmetry.