- A higher CTR means the ads reach a more suitable audience.
- A lower Position value (1 is lower than 2) means less was paid for the ads.
- A higher Revenue/Cost ratio (
ratio = revenue / (impressions * cost)
, assuming cost is per impression) means the campain is more profitable.
The SEM Performance metric (SEMP) will be (impressions * cost * position) / (ctr * revenue)
. The smaller SEMP
is, the better.
- Install python 3
- Give script execute permission
chmod +x measure_semp.py
- Run script with data file
./measure_semp.py take_home_test_data.csv
- Refactor logic into a class for better reusability and testability
- Write tests