Skip to main content


The UPLIFT command is very similar to the AB_TEST command, where we are calculating how effective an A/B test has been. UPLIFT goes on step further than finding statistical significance, by calculating the effectiveness of the A/B test.

UPLIFT calculates the uplift or treatment_effect of applying a treatment to an entity (i.e. a user, customer, etc).

Common use cases for uplift modelling include:

  • Measuring the effectiveness of advertising campaigns on KPIs like sales
  • Measure the effectiveness of a new feature using a KPI like product engagement

By measuring how effective a treatment is to specific individuals, you can then prioritise who to target with new features, or who to spend your ad campaign money on!

The UPLIFT command takes two inputs: the target column (the column we wish to compare, e.g. conversion, churn, click-through-rate), and the treatment column (i.e. the group they belong to - A/B, gender, location... whatever you wish!). By default, the treatment column is assumed to be treatment, and needs to be specified otherwise.

Similar to PREDICT, UPLIFT will use all the input columns to estimate the treatment_effect. Under-the-hood, we use causal machine-learning models to do this.

The output will contain one new column, treatment_effect, i.e. the conditional average treatment effect, or how effective a treatment is expected to be for a particular individual.


UPLIFT(<column_name>, [treatment=<column_name>>])


  • treatment can be used to specify the column defining the group (A/B, advertising campaign, gender, etc). Default is treatment.


Returns the conditional average treatment effect (treatment_effect) for each row of data, indicating how effective the treatment would be on that individual.


A/B test to see if a new feature increases usage.

SELECT * FROM user UPLIFT(total_hours_active_per_week, treatment=feature_group)

Calculate the effectiveness of a marketing campaign on individuals.

SELECT * FROM user UPLIFT(total_sales, treatment=saw_campaign)

Statistical test to see gender affects the types of products users buy.

SELECT * FROM user UPLIFT(product_category, treatment=gender)