-
Notifications
You must be signed in to change notification settings - Fork 10
Point biserial correlation coefficient
Maurice HT Ling edited this page Aug 13, 2021
·
4 revisions
Purpose: To measure the strength of relationship between a binary variable (X) and continuous variable (Y).
Null hypothesis: Correlation coefficient = 0
Alternate hypothesis: Correlation coefficient ≠ 0.
Code:
>>> from scipy import stats
>>> X = [1, 0, 1, 0, 1]
>>> Y = [5, 6, 7, 8, 7]
>>> result = stats.pointbiserialr(X, Y)
>>> print("Point biserial correlation coefficient = %.3f" % result.correlation)
Point biserial correlation coefficient = -0.320
>>> print("p-value = %.3f" % result.pvalue)
p-value = 0.599
Reference
- Lev J. 1949. The Point Biserial Coefficient of Correlation. Annals of Mathematical Statistics 20(1), 125-126.
Copyright (c) 2008-2024, Maurice HT Ling
Refereed Publications and Technical Reports
Abstracts and Other Un-Refereed Works
Autobiographic Verses (Poems that I wrote) and My Sayings