Announcement

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

  • psmatch2 _weight

    Can anyone help me with missing values for the _weight variable with the psmatch2 command? My main analyses are multivariate logistic regressions but I want to account for selectivity into one of the 2 groups that make up my sample. So this isn't really propensity score matching but instead weighting my main analyses according to membership in one of the 2 groups of respondents.

    Colleagues recommended I use the _weight variable resulting from psmatch2 as a probability weight ("[pweight=_weight]") in my mlogit models. However, I have a massive amount of missing on _weight even with options for ties or nearest-neighbor. As a result, the mlogit models only cover about half of my sample because respondents with _weight=. are excluded. It seems the issue lies in a lack of perfect matches or 1:1 matches but still requiring full information of _weight values. Does anyone have tips or advice? Thanks in advance!!

  • #2
    Here is my psmatch2 code to create weights for being in the mother or child generation based on variables associated with the mother generation (i.e., early childbearing) : "psmatch2 genr magebir rhisp rblack aendsch collpar2 biopar reg_s urban mbornus sibs, logit ties"

    And here is my mlogit code predicting employment and schooling cluster based on mother-child generation and a few demographic covariates: "mlogit tclust5 genr ageint female rhisp rblack [pweight=weight], b(2)"

    Thanks again!

    Comment


    • #3
      You could look at inverse propensity score weighting. There you're generating the weights from the propensity score estimation rather than from the matching process so you shouldn't have missing values (except for cases missing variables included in your propensity score model).

      Comment


      • #4
        Thank you for the advice, Sarah! Inverse propensity score weighting is exactly what I'm trying to do. With the psmatch2 command, I was under the impression that the _weight variable could serve that function but the large amount of missing was a problem. Can I use the _pscore variable generated from psmatch2 to manually calculate the inverse propensity score weight with the following equation?

        w(t,x) = (t/1) + [(1-t)/(1-e(x))] where w = weight, 1 = treatment, e(x) = propensity to have received treatment

        Comment


        • #5
          Hi Chelsea,
          The weight variable calculated from the psmatch2 command will give you weights specific to whatever matching strategy you specified, so the manual calculation you listed above will not give you the correct inverse probability weight.

          There are two options to get inverse probability weights:
          1) The teffects command calculates the weight and treatment effect in one command: teffects ipw (outcome) (treatment covariate1… covariate#)

          2) Or you can do the following to calculate weights, which you can then use in further analyses.

          qui dr outcome1 treatment covariate 1… covariate #, genvars (This will generate a variable named "iptwt")

          and then normalize the weights to sum to one:
          egen sumofweights = total(iptwt)
          gen norm_weights = iptwt/sumofweights

          Hope this helps,
          Melissa

          Comment


          • #6
            Hi Melissa, I ran into the same issue here and I was trying to understand your syntax here. Could you explain a little bit about what does qui dr mean here?

            Comment


            • #7
              Code:
              help qui
              help dr
              should answer your question.
              Last edited by Steve Samuels; 03 Nov 2017, 16:28.
              Steve Samuels
              Statistical Consulting
              [email protected]

              Stata 14.2

              Comment


              • #8
                Sorry, dr is not a built-in command. You'll need
                Code:
                findit dr
                Steve Samuels
                Statistical Consulting
                [email protected]

                Stata 14.2

                Comment


                • #9
                  Hmm, can anyone help me where to find the dr command? "findit dr" does not help me finding the right package.

                  Comment


                  • #10
                    Originally posted by Mads Oernfeldt View Post
                    Hmm, can anyone help me where to find the dr command? "findit dr" does not help me finding the right package.
                    Code:
                    findit st0149
                    Last edited by Øyvind Snilsberg; 02 Dec 2021, 03:31.

                    Comment


                    • #11
                      Thanks Snilsberg!

                      Comment

                      Working...
                      X