# Computing elasticity of log-transformed variable in probit model

I would like to estimate the own-and cross-price elasticities of demand of a health product. Consider following model:

$Product_{ij}=\beta_0+\beta_1ln(priceA)_j+\beta_2ln(priceB)_j+\beta_3Insurance_{ij}+X\beta+\epsilon_i+\nu_j$

Where:

1. The indices $i$ and $j$ represent the individual and village, respectively
2. $Product$ is a binary variable which takes on the value of 1 if the respondent chose Product B and 0 if the person chose Product A
3. $ln(priceA)$ is the average price of Product A in the village
4. $ln(priceB)$ is the average price of Product B in the village, and
5. $Insurance$ is a binary variable indicating whether the person has health insurance coverage (1) or otherwise (0)

I fitted a probit model because the outcome variable is binary. I am unsure how to calculate the elasticity. Given that the prices of products A and B are both entered in the model with the log transformation, would I calculate the elasticity (EY/EX) of the log-transformed variable or a semi-elasticity (EY/DX)?

• Have you seen this? – Dimitriy V. Masterov Oct 23 '15 at 18:00
• Thanks, @DimitriyV.Masterov. My Greek and calculus are a little rusty, but is the derivative (($\delta Pr(y=1|x)/\delta x$) ) essentially the elasticity then? – Marquis de Carabas Oct 24 '15 at 22:24

In Stata, you can calculate this like this:

. sysuse auto, clear
(1978 Automobile Data)

. gen lnx = ln(mpg)

. qui probit foreign lnx weight, nolog

. margins, expression(normalden(xb())*_b[lnx]/100)

Predictive margins                              Number of obs     =         74
Model VCE    : OIM

Expression   : normalden(xb())*_b[lnx]/100

------------------------------------------------------------------------------
|            Delta-method
|     Margin   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
_cons |  -.0070446   .0022689    -3.10   0.002    -.0114915   -.0025977
------------------------------------------------------------------------------


This can be interpreted as saying that a 1% increase in miles per gallon is associated with a 0.007 reduction in the probability of the car being imported (on a [0,1] scale), holding the weights of the cars constant.

• Thanks, Dimitriy. I was not familiar with -margins, expression-. I am now reading the help file for -margins- and educating myself about it. Thanks again – Marquis de Carabas Oct 25 '15 at 2:09
• If you're OK with dividing by 100 yourself (or just considering what happens when mpg doubles), you could have just used margins, dydx(lnx). I prefer my way since you can adjust the factor to whatever a reasonable change in x is in your setting, and it is a little less black box. – Dimitriy V. Masterov Oct 25 '15 at 2:16
• You know, I have always wondered what goes under the hood. I agree less black box is better and I also prefer to have more control over what goes into the expression. Thank you again for this, mate! – Marquis de Carabas Oct 25 '15 at 2:33