jpvanhal / flask-split

A/B testing for your Flask application.
https://flask-split.readthedocs.io/
MIT License
120 stars 37 forks source link

Weights on alternatives #11

Open naveediitb opened 4 years ago

naveediitb commented 4 years ago

Hi,

I was trying to test an uneven split(90-10) by providing weights on alternatives for an experiment and it looks like the weights are not taken into consideration

experiment_name = "check_uneven_90_10" alternatives = [("A", 90), ("B", 10)] ab_test(experiment_name, *alternatives)

Also tried with alternatives = [("A", 0.9), ("B", 0.1)]

I am still seeing an even(~50-50) split

Screen Shot 2020-07-31 at 7 52 45 AM

Please let me know if I am missing something or I am using this correctly? Thanks in advance.

naveediitb commented 4 years ago

Hi @jpvanhal - I have created a PR and suggested an update that can fix this issue. Please have a look and thank you for creating the repo