Announcement

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

  • #16
    Originally posted by FernandoRios View Post
    Hi Sharnaz
    2. one way for pretrend analysis would be using "never" as control, and "estat event, predict(xb)" since the idea is to test if the latent variable exihibits PTA not the Actual predicted probability.
    Hi Fernando,
    Thank you for your earlier help. I did not send a thank you post earlier to keep this post tidy.
    I have an additional question. In some of my jwdid estimations, "estat event, predict(xb)" gives the following result:
    Code:
    . estat event, predict(xb)
    last estimates not found
    r(301);
    Is there anything that I am doing wrong. The error occurs when I estimate "method(mlogit)". There is no problem with the estimation and I get results for that. But post estimation command cannot find it. I tried method(logit) with the same data and estat gives me the margins.

    Code:
    jwdid CATEGORICAL_OUTCOME, tvar(YEAR) gvar(GVAR) never group method(mlogit)
    jwdid CATEGORICAL_OUTCOME [pw=WEIGHT], tvar(YEAR) gvar(GVAR) never group method(mlogit)

    Comment


    • #17
      two points
      1. Do you have latest jwdid?
      2. are you using " estat event, predict(xb)" right after jwdid?
      The problem you mention usually occurs when jwdid info (the contents in e()) is not available.
      For instance, you say estat event gives you that error, but i do not know what happen between jwdid and estat
      F

      Comment


      • #18
        1. Yes, I just updated all my stata packages using "ado update, update" to make sure about the version of jwdid. If this is not the correct way to update jwdid in my stata, please let me know.
        2. Yes, I use it immediately after running jwdid commands in #16.
        Thank you.

        Comment


        • #19
          what Stata version you have?
          and can you try the following in your computer?

          Code:
          ssc install frause
          frause mpdta
          gen r=runiform()>.5
          jwdid r , ivar(county) time(year) gvar(first) never method(logit) group
          estat event, predict(xb)
          And tell me if it gives you an error (it doesn't on my end)
          F

          Comment


          • #20
            STATA 17.0 I also have 15 but have not tried in 15. Should I?
            Your code works with no error. But with multinomial logit, I get that error, not in logit. Again with this data, when I used mlogit, I received the same error
            Last edited by Saharnaz Babaei; 19 Apr 2023, 19:59.

            Comment


            • #21
              Same error in STATA 15.0 after runing

              Code:
              ssc install frause
              frause mpdta
              gen r=runiform()>.5
              jwdid r , ivar(county) time(year) gvar(first) never method(mlogit) group
              estat event, predict(xb)

              Comment


              • #22
                Sorry didnt read you were using mlogit.
                Right now it wont work with that because of some internal coding conflict with mlogit. I will try to see how to go around it for future update

                Comment


                • #23
                  Thank you. Then, I will update my results later using mlogit. I also have another question about post-estimation commands using logistic method. Is there a way to get margins for control variables too? I only get margin for treatment variable. But I would like to report the margins/coefficients for my control variables as well.
                  Last edited by Saharnaz Babaei; 21 Apr 2023, 09:16.

                  Comment


                  • #24
                    No, the treatment effects can only be estimated using estat for the overall treatment. For controls is not possible because of how variables are defined.

                    Comment


                    • #25
                      Could anyone help me with understanding why after
                      Code:
                      estat event, predict(xb)
                      the standard error of first and last period are too big? Here is the result I get:
                      Data is restricted and I cannot share. It is a repeated cross sectional survey data. it has 5 waves.
                      There is variation in timing of the policy.
                      With "if" condition, I limit the years to the first 4 waves or last 4 waves and again I get a large std err for year 2 which becomes the last year in this case.
                      I estimate with and without covariates, again the first and last years have large std errs.
                      I would appreciate it if you could let me know what other things I should try. Thank you.

                      Code:
                      jwdid y x [pw=TWGT], tvar(waveyear) gvar(policy_year) never group method(logit) cluster(S)

                      Delta-method
                      coeff. std. err. z p
                      _at@__event__
                      (2 vs 1) -4 -3.0 0.8 -3.8 0.0
                      (2 vs 1) -3 0.7 0.3 2.6 0.0
                      (2 vs 1) -2 -0.2 0.2 -1.0 0.3
                      (2 vs 1) -1 0 omitted
                      (2 vs 1) 0 -0.6 0.2 -3.3 0.0
                      (2 vs 1) 1 -0.6 0.2 -3.2 0.0
                      (2 vs 1) 2 -0.5 0.5 -1.1 0.3
                      (2 vs 1) 3 2.6 2.3 1.1 0.3

                      Comment


                      • #26
                        Why would not it need to be “big”
                        keep in mind that compared to the other dynamic effects, the last and first have the fewer observations

                        Comment


                        • #27
                          Originally posted by FernandoRios View Post
                          Why would not it need to be “big”
                          keep in mind that compared to the other dynamic effects, the last and first have the fewer observations
                          I wanted to make sure I'm not doing anything wrong causing that.

                          Comment


                          • #28
                            Following Wooldridge paper
                            add vce(unconditional) to your command

                            Comment


                            • #29
                              Originally posted by FernandoRios View Post
                              Following Wooldridge paper
                              add vce(unconditional) to your command
                              But jwdid does not allow vce() in options

                              Comment


                              • #30
                                not jwdid, but directly estat

                                estat event, vce(unconditional)

                                Comment

                                Working...
                                X