Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(experiments): Calculate win probability against control #27804

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

danielbachhuber
Copy link
Contributor

@danielbachhuber danielbachhuber commented Jan 22, 2025

See #26713
See https://posthog.slack.com/archives/C07PXH2GTGV/p1737374020186379

Changes

Switches all three win probability calculations to calculate the win probability solely against the control, instead of absolute win probability. Docs update: PostHog/posthog.com#10437

Tests document the difference between v1 and v2 behavior.

How did you test this code?

Tests should pass.

Copy link
Contributor

@andehen andehen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

This tool-tip explanation is outdated now
Screenshot 2025-01-23 at 13 43 02

- The first element is the probability that the control variant is the best
- Subsequent elements are the probabilities that each test variant is the best
A list of probabilities where each element represents:
- index 0: probability control variant beats all test variants
Copy link
Contributor

@andehen andehen Jan 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, control is a little tricky for this new behavior. Take this example:

  • control and two variants, all equally good
  • each variant will have a 50% chance to win (50/50 to beat control)
  • control will only get a 33% chance to beat both variants.

So one can no longer compare these values then. Control will look worse than it is.

What I suggest we do, is that we for control show the probability to beat the best variant. I think that will be more meaningful to the user. And maybe update the description to say "Probability to beat control" and "Probability to beat best variant", respectively.

Alternatively, we could also drop showing this value for control.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What I suggest we do, is that we for control show the probability to beat the best variant. I think that will be more meaningful to the user.

Sounds good. Updated with 25a4231 and changed the tooltip with effb992

Copy link
Contributor

Size Change: 0 B

Total Size: 1.16 MB

ℹ️ View Unchanged
Filename Size
frontend/dist/toolbar.js 1.16 MB

compressed-size-action

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants