example-app-ab-testing
example-app-ab-testing copied to clipboard
Two-sided p-value calculation possibly incorrect?
Shouldn't it be something like this?
if hypothesis == "One-sided" and z < 0: return 1 - norm().sf(z) elif hypothesis == "One-sided" and z >= 0: return norm().sf(z) / 2 elif z < 0: return (1 - norm().sf(z)) * 2 else: return (norm().sf(z)) * 2