Skip to main content

In the current experimentation UI in amplitude. we have the option to target all user or based on user property, 

but what we need is to target based on specific event.

lets imagine that we have a funnel and 

  1. Viewed landing page (first event in the funnel) 
    Amplitude normally assign users on variants before or after this event get fired 
  2. Clicked on product carousel 
    this is the event that we want to start assigning when it happen to include only in the experiment users who have done this event and the variants (treatment / control) should get exposed after firing this event.

How to work on implementing solution 2. 
is there is a way from amplitude ui or it should be done using code ? and if with code, how to do it ?       

Hello Ahmed,

In Amplitude Experiment, the assignment to an experiment happens when the `fetch()` method is called in your code. This is usually done after you initialize the Experiment. The `fetch()` method triggers the assignment event, which indicates what variant a user was assigned to based on your targeting rules. A user must be assigned to a variant in order for them to receive the variant’s experience.

If you want to delay the assignment until users have completed specific actions in your product (like 'Clicked on product carousel'), you could adjust your code to call the `fetch()` method only after these actions have been completed. This way, the assignment (and thus the mutual exclusion) would only take place at this point, allowing you to run each experiment on 100% of the population.

You can find more information about the assignment event in this documentation.

I hope it answered to your question, if you have any other question, feel free to ask.

Best regards,

Ben


P.S. Checkout upcoming events and user meetups on our events page.

Reply