ttest_1samp elif num_samples == 2: if independent: valid_tests = { 'mannwhitneyu': stats.mannwhitneyu, 'kruskal': stats.kruskal, 'ks_2samp': stats.ks_2samp } if normal: valid_tests['two_sample_ttest'] = stats.ttest_ind if equal_var: valid_tests['f_oneway'] = stats.f_one...
kstest( # Beta is a univariate distribution. sample_values, stats.beta(a=1., b=2.).cdf)[0], 0.01) # The standard error of the sample mean is 1 / (sqrt(18 * n)) self.assertAllClose(sample_values.mean(axis=0), stats.beta.mean(a, b), atol=1e-2) self.assertAllClose(np....