Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Dear Dimitriy, Thanks for the reply. In fact, I have seen the example. But, my question is, do we need any theoretical derivation to prove that it is correct by doing what you suggested in the example?

    Ho-Chuan (River) Huang
    Stata 17.0, MP(4)

    Comment


    • #17
      Originally posted by Clyde Schechter View Post
      You do not say whether you have panel (longitudinal) data or not. It makes a difference. You also do not say whether your time variable is a simple pre-post dichotomy or if you have multiple time periods before and after. Anyway, let me assume that you do not have panel data and that either your time variable is a simple pre-post dichotomy (or that you have calculated a simple pre-post dichotomy variable from your time variable). Then the basic code is

      Code:
      probit outcome i.treatment##i.pre_post /*INSERT COVARIATES HERE*/
      You will probably also want to look at the model-predicted probabilities of the outcomes in both groups in both eras, and the group differences in both eras and time-related changes in both groups.

      Code:
      margins treatment#pre_post
      margins treatment, dydx(pre_post)
      margins pre_post, dydx(treatment)
      The use of covariates in the model will not alter the interpretation of the coefficient of the interaction term as the DID estimator of the treatment effect. It will simply mean that your estimate is adjusted for your covariates.
      Dear Dr. Schechter,
      how could I compute margins in probit DiD regression?

      Description: no panel data
      after = 1 if 2004, 2010, 2012
      after=0 if 1996, 1999
      patrilineal is a continuous treatment, it is the share of patrilineal societies within a certain region, it takes values from 0 to 1

      This way does not function in Stata, I get the following error :
      patrilineal: factor variables may not contain noninteger values
      Code:
      margins treatment#pre_post
      margins treatment, dydx(pre_post)
      margins pre_post, dydx(treatment)
      The model:
      Code:
      probit at_least_one_child_died c.patrilineal##i.after c.population_factor c.Protestant_share c.Muslim_share c.Catholic_share c.matrilineal c.avg_cropland_regions c.wealths_avg c.reads_control c.radio c.antetnusno_avg c.biofwthtsdrmdhs_avg c.age i.urban i.geo_tz1996_2015, robust

      How should I code this probit DiD and its margins?
      Thank you very much for your time and help.
      Regards, Veronika
      Last edited by Veronika Valcikova; 10 Apr 2020, 05:46.

      Comment


      • #18
        Because patrilineal is a continuous variable, it cannot be used in -margins- the same way as a discrete treatment variable. You have to select particular values of patrilineal that are of interest to you and then calculate the margins at those values of treatment. Let's say you are interested in patrilineal = 0, 0.1, 0.3, 0.5, 0.7, and 1.0. Then the code would be:

        Code:
        margins pre_post, at(patrilineal = (0 0.1 0.3 0.5 0.7 1.0))
        margins, dydx(after) at(patrilineal = (0 0.1 0.3 0.5 0.7 1.0))
        margins after, dydx(patrilineal)

        Comment


        • #19
          Thank you very much Clyde! This was really helpful. Regards, Veronika

          Comment


          • #20
            Hi All, I wanted to run a probit Diff-in-Diff model with explanatory variables. I gone through the literature of DiD especially by Atheyand Imbens(2006) and Puhani (2008). I have a discrete outcome with discrete and continous explanatory variables. The interest of this model is to find the interaction term of treatment and time for identifying the treatment effect. Moreover, as I intend to add co-variates in the model will it have any interpretation or inference issues. Moreover, I will be great full if anyone can show me how to build and interpret the coefficient of interaction term as the DiD estimator of the treatment effect. Regards Innocent

            Comment


            • #21
              Hi All, I wanted to run a probit Diff-in-Diff model with explanatory variables. I gone through the literature of DiD especially by Atheyand Imbens(2006) and Puhani (2008). I have a discrete outcome with discrete and continous explanatory variables. The interest of this model is to find the interaction term of treatment and time for identifying the treatment effect. Moreover, as I intend to add co-variates in the model will it have any interpretation or inference issues. Moreover, I will be great full if anyone can show me how to build and interpret the coefficient of interaction term as the DiD estimator of the treatment effect. Regards Innocent

              Comment


              • #22
                Hi All, I wanted to run a probit Diff-in-Diff model with explanatory variables. I gone through the literature of DiD especially by Atheyand Imbens(2006) and Puhani (2008). I have a discrete outcome with discrete and continous explanatory variables. The interest of this model is to find the interaction term of treatment and time for identifying the treatment effect. Moreover, as I intend to add co-variates in the model will it have any interpretation or inference issues. Moreover, I will be great full if anyone can show me how to build and interpret the coefficient of interaction term as the DiD estimator of the treatment effect. Regards Innocent

                Comment


                • #23
                  Dear all,

                  I have a similar problem. I am using a DiD approach but my dependent variable is binary (employed or not). I have already identified my control and treament group as well as pre and post period.

                  Can somebody please help with the commands for the regression.
                  Thanks a lot.

                  Comment


                  • #24
                    Dear Clyde, May I say that (according to your answer in #2) policy effect (the coefficient on the interaction term in the usual/continuous cases) is measured by
                    Code:
                    margins, dydx(treatment#pre_post)
                    Last edited by River Huang; 08 Nov 2021, 05:06.
                    Ho-Chuan (River) Huang
                    Stata 17.0, MP(4)

                    Comment


                    • #25
                      No. In fact, that code will just produce an error message, because there is no such thing as the marginal effect of an interaction term. The policy effect, in a linear regression model, is given by the coefficient of the interaction term in the regression command. It does not involve the -margins- command at all.

                      However, in a probit model it's more complicated than that. Coefficients in probit models are very difficult to explain in real world terms. The coefficients quantify differences in a latent normal variable which is then subjected to a threshold to determine a dichotomous outcome. In particular, it is very difficult to see intuitively what a given probit coefficient corresponds to in terms of outcome probabilities. So that is where the -margins- command comes in. I would use it to determine the marginal effect (in probability metric) of treatment in each era (pre and post) and then look at the difference between those. This can be done simply with
                      Code:
                      margins pre_post, dydx(treatment) pwcompare
                      That gives you the DID estimator of treatment effect in the outcome probability metric, which is a lot more understandable than in the probit coefficient metric.

                      Comment

                      Working...
                      X