View source: R/GoricEvSyn_LLandPT.r
GoricEvSyn_LLandPT | R Documentation |
GORIC(A) evidence synthesis (GoricEvSyn) aggregates the evidence for theory-based hypotheses from multiple studies that may use diverse designs to investigate the same central theory. There is also an interactive web application on my website to perform GoricEvSyn: https://www.uu.nl/staff/RMKuiper/Websites%20%2F%20Shiny%20apps.
GoricEvSyn_LLandPT(
TypeEv,
S,
LL,
PT,
Name_studies = 1:S,
Name_Hypo = NULL,
PrintPlot = T
)
TypeEv |
The type of evidence-synthesis approach: Equal-evidence approach (0) or Added-evidence approach (1). In case of an equal-evidence approach, aggregating evidence from, say, 5 studies with n=100 observations is the same as obtaining evidence from 1 study (as if it was possible) with n=500 observations (like meta-analysis does). In the added-evidence approach, the aggregated evidence from, says, 5 studies is stronger than as if the data were combined (as if that was possible). |
S |
The number of (primary) studies. That is, the results (evidence) of S studies will be aggregated. |
LL |
A matrix with log likelihood values of size S x 'NrHypos+1', where 'NrHypos+1' stands for the number of theory-based hypotheses plus a safeguard hypothesis (the complement or unconstrained). Notably, only when the set of hypotheses cover the whol space / all theories (e.g., positive versus negative effect), then you can do without a safeguard hypothesis. |
PT |
A matrix with penalty values of size S x 'NrHypos+1', where 'NrHypos+1' stands for the number of theory-based hypotheses plus a safeguard hypothesis (the complement or unconstrained). Notably, only when the set of hypotheses cover the whol space / all theories (e.g., positive versus negative effect), then you can do without a safeguard hypothesis. |
Name_studies |
Optional. Vector of S numbers or S characters to be printed at the x-axis of the plot with GORIC(A) weights. Default: Name_studies = 1:S. |
Name_Hypo |
Optional. Vector containing 'NrHypos+1' characters which will be used for labelling the hypothesis. Default: H1, H2, .... |
PrintPlot |
Optional. Indicator whether plot of GORIC(A) weigths should be printed (TRUE; default) or not (FALSE). The GORIC(A) weights per study are plotted and the cumulative GORIC(A) weights (where those for the last study are the final ones). |
The output comprises, among other things, the cumulative and final evidence for the theory-based hypotheses.
S <- 4
# Example based on S = 4 studies and 3 hypotheses:
# H0 <- "beta1 == 0" # this hypothesis could have been left out
# Hpos <- "beta1 > 0"
# Hneg <- "beta1 < 0"
# Note that in this set the whole space is (all theories are) covered so the unconstrained is not needed as safeguard-hypothesis
LL <- myLLs
PT <- myPTs
# Added-evidence approach
TypeEv <- 1
GoricEvSyn_LLandPT(TypeEv, S, LL, PT)
# Equal-evidence approach
TypeEv <- 0
GoricEvSyn_LLandPT(TypeEv, S, LL, PT)
# Change labels on x-axis in GORIC(A) weigths plot and give names to hypotheses #
# For example, let us say that the studies come from the years 2015, 2016, 2017, 2019.
# Because of unequal spacing, you may want to use numbers instead of characters:
Name_studies <- c(2015, 2016, 2017, 2019)
Name_Hypo <- c("H0", "Hpos", "Hneg")
GoricEvSyn_LLandPT(TypeEv, S, LL, PT, Name_studies, Name_Hypo)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.