Skip to content
RED SAGSkills
hardData Scientist interview question

The business wants to know how demand responds to price for thousands of products. How would you estimate price elasticity?

What the interviewer wants to hear

  • Observational price changes are confounded by demand and promotions
  • Use experiments or natural variation such as staggered price changes
  • Log-log models give elasticity as a coefficient
  • Pool across products with hierarchical models for sparse items
  • Control for seasonality, competitors, stock-outs and cannibalisation

Model answer

The core problem is confounding: prices are often cut when demand is low or raised during peaks, so a naive regression of sales on price gives the wrong sign or size. The best data comes from randomised price tests across stores or time, and the next best from natural variation like staggered price changes or cost-driven changes unrelated to demand. I would model log units against log price, so the coefficient is the elasticity, with controls for seasonality, promotions, competitor prices and holidays. Stock-outs must be handled, because zero sales when out of stock is not low demand. With thousands of products, many have little price variation, so I would use a hierarchical model that shrinks each product towards its category average. I would also check cross-effects, since cutting one price can cannibalise similar products, and validate predictions on held-out price changes before using them for pricing.

Can you answer it under time pressure?

Take a timed hard round and get scored on every answer.

Start mock interview

More hard Data Scientist questions