I'm trying to model price elasticity based on price changes and I'm wondering what is the best way to do it.
My data is at at the individual customer level and there's a 0/1 indicator for whether they purchased or not purchased.

The price changes that I'm referring to occurs at different times and different amount depending on state (i,e TX had a 5% rate increase in June, but Washington may have had a 9% decrease in April).

If I do a logistic regression of Buy/notBuy ~ price change + variable1 + variable2 +.....variableN, is my coefficient for price change what I would use as my 'elasticity'? Since it's logodds, how do I convert that to an elasticity level?

Since there's different price changes at different time and at different amount, is it better to model at different price change buckets?

appreciate any pointers on how to start.

  • $\begingroup$ Usually, Price Elasticity is modeled and defined on macro data being defined as giving 'the percentage change in quantity demanded in response to a one percent change in price'. See , for example, work here towardsdatascience.com/… 'Price Elasticity of Demand, Statistical Modeling with Python'. $\endgroup$
    – AJKOER
    May 14, 2020 at 23:41
  • $\begingroup$ thanks. so in my case, I'm using buy and not buy as my demand. for example, for a given state if I quoted 500 and sold 26, vs after the price change, if I quoted 700 and sold 34, the ratio would be my change in demand. $\endgroup$
    – semidevil
    May 14, 2020 at 23:53
  • $\begingroup$ I believe what you need to research is called the 'bid-response' function - probability of winning a bid given the price, and you have a corresponding bid-response elasticity. see eg business.columbia.edu/sites/default/files-efs/imce-uploads/CPRM/… $\endgroup$
    – seanv507
    Mar 23 at 22:11

1 Answer 1


Price elasticity (PE) is defined as the ratio of the relative change in demand of a product to the relative change in price of the product. Price elasticity is a property of the product and for the sake of analysis, let's suppose it remains constant with time. REF

We could consider aggregating our data to represent the demand at different price points. Also, we would like to have multiple observations from the same price point, since we have observational data and observational data is gonna have noise. Having multiple data points would allow us to see the trend and see through the noise. But we also want to make sure that the multiple observations should be of a similar kind and should have equal chances of attracting demand.

So keeping in mind the above ideas, this is what we can try:

  1. For a given time unit (say an hour, a day, a week, .....) count the average price observed and the total units sold.
  2. Log transform the demand and price, and regress the log of demand with the log of price with an intercept.
  3. The slope estimate should serve as an estimate of the product's elasticity.

The logic behind point 2 is the following:

$$\frac{\Delta(\text{demand})}{\text{demand}} = \text{elasticity} * \frac{\Delta(\text{price})}{\text{price}}$$


$$\log(\text{demand}) = \log(\text{price}) * \text{elasticity} + C$$

(Taking integrals on both sides from the previous equation, $C$ is the constant of integration.)

Therefore, the slope of the regression line and the intercept would serve as an estimate of elasticity and $C$ respectively.

This should be a good point to start.

We could then have different rows for different geographies. And choose to regress either all rows together, in which case we are assuming the product has the same elasticity in different geographies or multiple lines for different geographies, hypothesizing different elasticities for different geographies.

We could also try regressing demand over price, the log of demand over price, and demand over the log of price, but each of the slope estimates will mean something different and would impose a somewhat different assumption over the relationship between the price and demand. But I would expect each of them to be directionally similar. Please note that only the above formulation recovers the actual price elasticity directly. In the case of the alternate formulations, the price elasticity estimates could be arrived at with some manipulations and assumptions.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.