Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: diff-in-diff in levels or in logs

From   Maarten Buis <>
Subject   Re: st: diff-in-diff in levels or in logs
Date   Thu, 2 May 2013 15:44:59 +0200

On Thu, May 2, 2013 at 3:18 PM, Jack Knife  wrote:
> I am estimating a difference in difference regression with stata...
> and I would like to know what would be the best approach:
> I estimate a difference in difference in levels: that is if my output
> variable is Y, treated individuals have the dummy D=1 and treatment
> period is in time T=2
> I run -reg Y T D T#D
> and the coefficient on T#D gives me the diff in diff estimates. But if
> Y is a count variable... how could I say that Y decreased by X% after
> the reform using the same approach?
> Should I regress log(Y) instead of Y?

You should not transform your dependent variable, instead you should
use a link function. However, for a fully saturated model like you
propose it just does not matter, either model gives you exactly the
same predicted values. Here is a discusion in terms of a binary
dependent variable:
<>, and
here is an example in terms of a log link function:

*------------------ begin example ------------------
sysuse nlsw88, clear
reg wage i.union##i.married
predict yhat1

poisson wage i.union##i.married
predict yhat2

assert yhat1 == yhat2
*------------------- end example -------------------
(For more on examples I sent to the Statalist see: )

Hope this helps,

Maarten L. Buis
Reichpietschufer 50
10785 Berlin
*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index