The formulation of the null and alternative hypotheses for the superiority
design differs depending on whether high or low scores on the dependent
variable represent superiority. In both cases, the null hypothesis (i.e., H0)
states that the population means of the experimental group and the control
group are equivalent. In the case where high scores correspond to
superiority, the alternative hypothesis states that the population mean of
the experimental group is higher than the population mean of the control
group. Thus, the alternative hypothesis goes in the positive direction (i.e.,
H+). In turn, in the case where low scores correspond to superiority, the
alternative hypothesis states that the population mean of the experimental
group is lower than the population mean of the control group. Thus, the
alternative hypothesis goes in the negative direction (i.e., H-). The
dependent variable must be continuous.
Since the main goal of super_bf is to establish superiority,
the resulting Bayes factor quantifies evidence in favor of the alternative
hypothesis. In the case where low values represent superiority we have BF-0,
whereas in the case where high values represent superiority we have BF+0.
Evidence for the null hypothesis can easily be calculated by taking the
reciprocal of the original Bayes factor (i.e., BF0- = 1 / BF-0 and BF0+ = 1 /
BF+0). Quantification of evidence in favor of the null hypothesis is
logically sound and legitimate within the Bayesian framework (see e.g., van
Ravenzwaaij et al., 2019).
super_bf can be utilized to calculate a Bayes factor based on
raw data (i.e., if arguments x and y are defined) or summary
statistics (i.e., if arguments n_x, n_y, mean_x, and
mean_y are defined). In the latter case, the user has the freedom to
supply values either for the arguments sd_x and sd_y
OR ci_margin and ci_level. Arguments with 'x' as a
name or suffix correspond to the control group, whereas arguments with 'y' as
a name or suffix correspond to the experimental group (i.e., the group for
which we seek to establish superiority).
For the calculation of the Bayes factor, a Cauchy prior density centered on 0
is chosen for the effect size under the alternative hypothesis. The standard
Cauchy distribution, with a location parameter of 0 and a scale parameter of
1, resembles a standard Normal distribution, except that the Cauchy
distribution has less mass at the center but heavier tails (Liang et al.,
2008; Rouder et al., 2009). The argument prior_scale specifies the
width of the Cauchy prior, which corresponds to half of the interquartile
range. Thus, by adjusting the Cauchy prior scale with prior_scale,
different ranges of expected effect sizes can be emphasized. The default
prior scale is set to r = 1 / sqrt(2).
super_bf creates an S4 object of class
'>baymedrSuperiority, which has multiple slots/entries (e.g.,
type of data, prior scale, Bayes factor, etc.; see Value). If it is desired
to store or extract solely the Bayes factor, the user can do this with
get_bf, by setting the S4 object as an argument (see Examples).