Bayesian Correlation
v1.0.2
Health Sciences context — reports the relationship between two continuous variables with BF₁₀. Is the vucut_kitle_indeksi ↔ LDL_kolesterol relationship real or mere chance? Pearson/Spearman/Kendall supported.
🎯 What is it for?
Instead of the classical correlation p-value, it reports BF₁₀; particularly valuable with small samples and in replication studies. In the Health Sciences context, the predicted direction of the relationship (ρ ≈ 0.48) between vucut_kitle_indeksi and LDL_kolesterol is tested with the Bayes Factor.
📌 When is it used?
- Two continuous variables — to seek direct evidence about direction and strength
- When you want to directly test the “no correlation” hypothesis
- As a replacement for a test that failed with p < .05 at small N
⚙ Assumptions
- Two continuous variables (vucut_kitle_indeksi, LDL_kolesterol).
- A linear relationship (Pearson) or a monotonic one (Spearman/Kendall).
- Outlier screening should be done beforehand with Bland-Altman/scatter.
📊 How to Run It in MerQur
Panel assignments (form fields in the program):
- Columns:
{'x_col': 'BMI', 'y_col': 'HbA1c'} - Parameters:
{'method': 'pearson'}
📊 Sample Dataset — Health Sciences
ℹ Note: The scenario, MerQur output and interpretation below were produced by actually running the real example dataset in MerQur. Numeric results on your own data will differ; the goal is to show how the analysis is set up and interpreted end-to-end.
🎬 Example File
This analysis is demonstrated on the following example dataset for Health Sciences:
Tip/102_bayesian_correlation_BMI_HbA1c_BF10.xlsx
🎬 Scenario
We evaluate the relationship between BMI and HbA1c in a Bayesian framework. For
evidential strength, Bayesian correlation is appropriate.
⚙️ Variable Selection
- 1st measure / group: BMI
- 2nd measure / group: HbA1c
Data Preview (First 5 Rows)
| patient_id | BMI | HbA1c | age |
|---|---|---|---|
| 1.0 | 28.16 | 8.62 | 49.0 |
| 2.0 | 21.92 | 8.31 | 33.0 |
| 3.0 | 24.64 | 9.44 | 61.0 |
| 4.0 | 29.56 | 10.24 | 40.0 |
| 5.0 | 33.78 | 9.49 | 28.0 |
n = 80 · Columns: patient_id, BMI, HbA1c, age
📈 MerQur Output
─────────────────────────────────────────────
r = 0.662 (strong) BF10 = 4.77e+08 (overwhelming evidence for a relationship)
💬 Interpretation
We evaluated the relationship between two variables (BMI x HbA1c) in a Bayesian framework: r = 0.66 and BF10 ~ 4.8e8,
i.e. very strong evidence for a relationship. Bayesian correlation, instead of a classical p-value, presents the
evidential strength of the relationship as a Bayes factor and the coefficient’s posterior distribution. In medicine
it is valuable for reporting not just whether the relationship between two clinical indicators is “significant” but
how strongly it is “evidenced”.
⚠ Common Mistakes
- Pearson is misleading for non-linear relationships — check the scatter plot, and use Spearman if needed.
- Outliers inflate or mask the correlation.
- Correlation ≠ causation (especially in observational studies).
📚 MerQur’a Atıf
Örücü, Ö. K. (2026). MerQur: Integrated Academic Data Analysis & Reporting Platform [Computer software] (Version 1.0.0). https://doi.org/10.53463/merqur.2026001
📝 Üretim Notu — Bu sayfadaki örnek veri sentetik olarak üretilmiştir (sabit SEED=42, generator: samples/Ileri_Duzey_v102/_generate_v102_datasets.py). Sayfa içeriği Anthropic Claude desteği ile hazırlanmış, akademik doğruluk yazar tarafından kontrol edilmiştir.