Interval estimation, correlation measures, and statistical tests
We briefly covered interval estimation as an introductory example of SciPy: bayes_mvs
, in Chapter 1, Introduction to SciPy, with very simple syntax, as follows:
bayes_mvs(data, alpha=0.9)
It returns a tuple of three arguments in which each argument has the form (center, (lower, upper))
. The first argument refers to the mean; the second refers to the variance; and the third to the standard deviation. All intervals are computed according to the probability given by alpha
, which is 0.9
by default.
We may use the linregress
routine to compute the regression line of some two-dimensional data x, or two sets of one-dimensional data, x and y. We may compute different correlation coefficients, with their corresponding p-values, as well. We have the Pearson correlation coefficient (pearsonr
), Spearman's rank-order correlation (spearmanr
), point biserial correlation (pointbiserialr
), and Kendall's tau for ordinal data (kendalltau...