scale_channel_lift_measurements#

pymc_marketing.mmm.lift_test.scale_channel_lift_measurements(df_lift_test, channel_col, channel_columns, transform)[source]#

Scale the lift measurements for a specific channel.

Parameters:
df_lift_testpd.DataFrame
DataFrame with lift test results with the following columns:
  • x: x axis value of the lift test.

  • delta_x: change in x axis value of the lift test.

  • channel_col: channel to scale.

channel_colstr

Name of the channel to scale.

channel_columnslist[str]

List of channel values in the model. All lift tests results will be a subset of these values.

transformCallable[[np.ndarray], np.ndarray]

Function to scale the lift measurements.

Returns:
pd.DataFrame

DataFrame with the scaled lift measurements.