lift_test_indices#

pymc_marketing.mmm.lift_test.lift_test_indices(df_lift_test, model)[source]#

Get the indices of the lift test results in the model.

Assumes any column in the DataFrame is a coordinate in the model with the same name.

Parameters:
df_lift_testpd.DataFrame

DataFrame with lift test results.

modelpm.Model

PyMC model with all the coordinates in the DataFrame.

Returns:
dict[str, np.ndarray]

Dictionary of indices for the lift test results in the model.

Raises:
MissingLiftTestError

If some lift test values are not in the model.