Skip to content

Ab test selection

AbTestSelection #

AbTestSelection(
    a_selections: Sequence[RapidataSelection],
    b_selections: Sequence[RapidataSelection],
)

Bases: RapidataSelection

AbTestSelection Class

Splits the userbase into two segments and serves them a different collection of rapids.

Useful for A/B Test.

Parameters:

Name Type Description Default
a_selections Sequence[RapidataSelection]

List of selections for group A.

required
b_selections Sequence[RapidataSelection]

List of selections for group B.

required
Source code in src/rapidata/rapidata_client/selection/ab_test_selection.py
def __init__(
    self,
    a_selections: Sequence[RapidataSelection],
    b_selections: Sequence[RapidataSelection],
):
    self.a_selections = a_selections
    self.b_selections = b_selections