zalando / expan

Open-source Python library for statistical analysis of randomised control trials (A/B tests)
MIT License
335 stars 50 forks source link

Fix two-sided alpha value in power analysis #173

Closed shansfolder closed 7 years ago

shansfolder commented 7 years ago

Aligned with Tomas

coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 92.034% when pulling 32442ae9f4151a634c3f73db96c685d7e660f318 on fix_power_analysis into 4d31973eabcb5774248572628a8a916d2f5279d5 on dev.

gbordyugov commented 7 years ago

could you please provide a little bit more background about this change?

shansfolder commented 7 years ago

As discussed, when we derive the formula of power analysis, it is based on the meeting point of false positive and false negative (beta). In our case, alpha is always two-sided, so the area of false positive that overlaps with beta is alpha/2.

(It's pretty hard to explain in plain words. If anyone has doubts, I can explain in person by drawing)

daryadedik commented 7 years ago

👍