9,821
Views
61
CrossRef citations to date
0
Altmetric
Articles

Bayesian rank-based hypothesis testing for the rank sum test, the signed rank test, and Spearman's ρ

ORCID Icon, ORCID Icon, ORCID Icon &
Pages 2984-3006 | Received 14 May 2019, Accepted 20 Dec 2019, Published online: 11 Jan 2020

Figures & data

Figure 1. The graphical model underlying the Bayesian rank sum test. The latent, continuous scores are denoted by Zix and Ziy, and their manifest rank values are denoted by xi and yj. The latent scores are assumed to follow a normal distribution governed by the parameter δ. This parameter is assigned a Cauchy prior distribution, which for computational convenience is reparameterized to a normal distribution with variance g (which is then assigned an inverse gamma distribution).

Figure 1. The graphical model underlying the Bayesian rank sum test. The latent, continuous scores are denoted by Zix and Ziy, and their manifest rank values are denoted by xi and yj. The latent scores are assumed to follow a normal distribution governed by the parameter δ. This parameter is assigned a Cauchy prior distribution, which for computational convenience is reparameterized to a normal distribution with variance g (which is then assigned an inverse gamma distribution).

Figure 2. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for logistic data. Because U is dependent on n, the rank biserial correlation coefficient is plotted on the x-axis instead of U. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when ρrb=0. The further ρrb deviates from 0, the stronger the evidence in favor of H1 becomes. The lines depict smoothing splines fitted to the observed Bayes factors.

Figure 2. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for logistic data. Because U is dependent on n, the rank biserial correlation coefficient is plotted on the x-axis instead of U. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when ρrb=0. The further ρrb deviates from 0, the stronger the evidence in favor of H1 becomes. The lines depict smoothing splines fitted to the observed Bayes factors.

Figure 3. For all combinations of difference in location parameters Δ, and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for logistic data. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement, as suggested by the ARE results in [Citation58].

Figure 3. For all combinations of difference in location parameters Δ, and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for logistic data. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement, as suggested by the ARE results in [Citation58].

Figure 4. Do students who flunk a math course report drinking more alcohol? Results for the Bayesian rank sum test as applied to the data set from [Citation9]. The dashed line indicates the Cauchy prior with scale 12. The solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case δ=0. The ratio of the ordinates gives the Bayes factor.

Figure 4. Do students who flunk a math course report drinking more alcohol? Results for the Bayesian rank sum test as applied to the data set from [Citation9]. The dashed line indicates the Cauchy prior with scale 12. The solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case δ=0. The ratio of the ordinates gives the Bayes factor.

Table 1. The scores, difference scores, ranks of the absolute difference scores, and the sign indicator function Q for the hypothetical scenario where X=(5,8,4) are the initial scores on a math exam and Y=(6,7,7) are the scores on the exam after a tutoring session.

Figure 5. The graphical model underlying the Bayesian signed rank test. The latent, continuous difference scores are denoted by Zid, and their manifest signed rank values are denoted by di. The latent scores are assumed to follow a normal distribution governed by parameter δ. This parameter is assigned a Cauchy prior distribution, which for computational convenience is reparameterized to a normal distribution with variance g (which is then assigned an inverse gamma distribution).

Figure 5. The graphical model underlying the Bayesian signed rank test. The latent, continuous difference scores are denoted by Zid, and their manifest signed rank values are denoted by di. The latent scores are assumed to follow a normal distribution governed by parameter δ. This parameter is assigned a Cauchy prior distribution, which for computational convenience is reparameterized to a normal distribution with variance g (which is then assigned an inverse gamma distribution).

Figure 6. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for logistic data. Because W is dependent on n, the matched-pairs rank-biserial correlation coefficient is plotted on the x-axis instead of W. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when ρmrb=0. The further ρmrb deviates from 0, the stronger the evidence in favor of H1 becomes. The lines are smoothing splines fitted to the observed Bayes factors.

Figure 6. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for logistic data. Because W is dependent on n, the matched-pairs rank-biserial correlation coefficient is plotted on the x-axis instead of W. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when ρmrb=0. The further ρmrb deviates from 0, the stronger the evidence in favor of H1 becomes. The lines are smoothing splines fitted to the observed Bayes factors.

Figure 7. For all combinations of difference in location parameters Δ, and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for logistic data. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement, with the latent normal Bayes factor accumulating evidence in favor of the true model faster.

Figure 7. For all combinations of difference in location parameters Δ, and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for logistic data. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement, with the latent normal Bayes factor accumulating evidence in favor of the true model faster.

Figure 8. Does progabide reduce the frequency of epileptic seizures? Results for the Bayesian signed rank test as applied to the data set presented in [Citation57]. The dashed line indicates the Cauchy prior with scale 12. The solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case δ=0. The ratio of the ordinates gives the Bayes factor.

Figure 8. Does progabide reduce the frequency of epileptic seizures? Results for the Bayesian signed rank test as applied to the data set presented in [Citation57]. The dashed line indicates the Cauchy prior with scale 12. The solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case δ=0. The ratio of the ordinates gives the Bayes factor.

Figure 9. The graphical model underlying the Bayesian test for Spearman's ρs. The latent, continuous scores are denoted by Zix and Ziy, and their manifest rank values are denoted by rix and rjy. The latent scores are assumed to follow a normal distribution governed by parameter ρ (which is assigned a uniform prior distribution).

Figure 9. The graphical model underlying the Bayesian test for Spearman's ρs. The latent, continuous scores are denoted by Zix and Ziy, and their manifest rank values are denoted by rix and rjy. The latent scores are assumed to follow a normal distribution governed by parameter ρ (which is assigned a uniform prior distribution).

Figure 10. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for data generated with the Clayton copula. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when Spearman's ρs=0. The further Spearman's ρs deviates from 0, the stronger the evidence in favor of H1 becomes. The lines are smoothing splines fitted to the observed Bayes factors.

Figure 10. The relationship between the latent normal Bayes factor and the observed rank-based test statistic is illustrated for data generated with the Clayton copula. The relationship is clearly defined, and maximum evidence in favor of H0 is attained when Spearman's ρs=0. The further Spearman's ρs deviates from 0, the stronger the evidence in favor of H1 becomes. The lines are smoothing splines fitted to the observed Bayes factors.

Figure 11. For all combinations of Spearman's ρs and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for data generated with the Clayton copula. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement.

Figure 11. For all combinations of Spearman's ρs and n, the relationship between the latent normal Bayes factor and the parametric Bayes factor is shown for data generated with the Clayton copula. The black lines indicate the point of equivalence. The two Bayes factors are generally in agreement.

Figure 12. Is performance on a math exam associated with the quality of family relations? Results for the Bayesian version of Spearman's ρs as applied to the data set from [Citation9]. The dashed line indicates the uniform prior distribution, and the solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case ρ=0. The ratio of the ordinates gives the Bayes factor.

Figure 12. Is performance on a math exam associated with the quality of family relations? Results for the Bayesian version of Spearman's ρs as applied to the data set from [Citation9]. The dashed line indicates the uniform prior distribution, and the solid line indicates the posterior distribution. The two grey dots indicate the prior and posterior ordinate at the point under test, in this case ρ=0. The ratio of the ordinates gives the Bayes factor.