Description Usage Arguments Details Value Author(s) Examples
The function can be used to calculate various effect sizes. See [metafor]{rma}
and [metafor]{escalc}
details.
1 2 | RunPoolEffect(var_of_interest, dataset, measure = "OR",
methodtype = "REML")
|
var_of_interest |
vector, the interesting variables. |
dataset |
dataframe, the results of multiRunRR. |
measure |
character, a character string indicating which effect size or outcome
measure should be calculated. See |
methodtype |
character, the specifying whether a fixed- or a random/mixed-effects
model should be fitted, See |
TODO
a results dataframe of the pooled data with the random-effect
model ot fixed-effect model. See the metafor{rma}
details.
Shuangbin Xu
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | library("MetaMicrobiome")
study <- c("Baxter_16",
"Deng_18",
"Flemer_17",
"Flemer_18",
"Hale_17",
"Mori_18",
"Zeller_15")
data <- lapply(study,
function(x){read.csv(system.file("data",
package="MetaMicrobiome",
paste(x, "_alpha_data.csv.gz", sep="")))})
names(data) <- study
threholds <- mapply(getthresholds, data,
MoreArgs=list(var_of_interest=c("Observe", "Shannon", "J"),
type="median"), SIMPLIFY=FALSE)
multiHighLowVector <- mapply(MultiHighLow,
data,
threholds,
MoreArgs=list(var_of_interest=c("Observe",
"Shannon",
"J")),SIMPLIFY=FALSE)
multiRRresult <- mapply(multiRunRR,
multiHighLowVector,
data,
MoreArgs=list(prefix="Group", grouptype="CRC"),
SIMPLIFY=FALSE)
multistudyRRresult <- mapply(multiVarRRTab,
multiRRresult,
MoreArgs=list(var_of_interest=c("Observe",
"Shannon", "J")),
SIMPLIFY=FALSE)
multistudyRRresult2 <- dplyr::bind_rows(lapply(study,
function(x)
dplyr::mutate(multistudyRRresult[[x]], study=x)))
multistudyRRresult2
pooledREML <- dplyr::bind_rows(mapply(RunPoolEffect,
c("Observe", "Shannon", "J"),
MoreArgs=list(dataset=multistudyRRresult2,
methodtype="REML"),
SIMPLIFY=FALSE))
head(pooledREML)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.