Announcement

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

  • ty Score Matching (psmatch2) panel data

    I want to use the routine proposed by Leuven and Sianesi (2003) to do the Propensity Score Matching but don't know how to start.
    I am using Stata 15 for Windows.

    PSM is at pagg. 14-16.
    In order to do this: "Matches are selected using the method of
    the nearest neighbour without replacement and within a caliper (0.01 percentage points), on the common
    support of tted probabilities" (note 7 of pag. 14), which command shall I use?

    After installingpsmatch2, I have typed help psmatch2, but I have got any idea how to proceed.

    I would like to know, if possible, the complete procedure to follow.

    Please find the attached.
    Neri, Rondinelli, Scoccianti (2017) - Banca d'Italia.pdf

  • #2
    Gabriele:

    It would assist others helping you with this question to provide a sample of your data using -dataex-. In addition, please provide a brief description of the variables and what you're trying to achieve.

    Comment


    • #3
      Junran Cao thanks a lot for your attention.

      So, I installed -dataex- and then I displayed this:

      Code:
      * Example generated by -dataex-. To install: ssc install    dataex
      clear
      input long NQUEST double nocomp byte(geoarea quaresponse    empact ageclass    educlev)    long    freecash    byte(income    makem)    double    deltas    byte(deltaempl    deltahigh    deltaop)    double    deltainbon    byte    bonus    float    eligible
      173   1 3  6 3 4 4  49737 5 4           .0507293996  0    0  0  0 0 0
      375   1 3  7 3 5 2  11320 2 2    .24073996200000003  0    0  0  0 0 0
      633   1 1  7 3 5 2  19933 4 2    .10081998550000001  0    0  0 -1 0 0
      923   1 3  8 3 5 2   9110 1 1           .1233986328  0    0  0  4 0 0
      1367 1.5 3  9 3 5 2  17351 2 3   .022523003799999997  0    0  0 -1 0 0
      1763 1.5 3  7 1 5 2  12840 1 2          -.1368697016 -1    0  0  0 0 0
      1927   1 1 10 3 5 3  10155 2 3           .2534579122  0    0  0  0 0 0
      1946   1 1 10 3 4 4  12067 2 4   .015820596700000022  0    0 -1  0 0 0
      2886   2 3  8 1 4 4  47125 4 4    .07715938389999999 -1    0 -2  0 0 0
      3717   1 3  8 2 4 4   5450 1 2           .2992447429  0    0 -1  0 0 0
      5416 2.8 1 10 1 3 2  29715 2 1    .22638912610000006 -2    0 -1  0 1 1
      7886 1.5 2 10 1 4 4  53774 5 3  -.029117032399999965  0    0 -2  0 1 1
      11972 1.5 3  7 3 4 2  72544 5 3   .012609497800000008  0    0  1 -1 0 0
      20297 1.5 1 10 1 3 3  21853 3 3     .8633676161000001 -1    0  0 -1 0 0
      20711 1.5 1 10 3 5 3  29711 4 3    -.5466930938000001  0    0  0 -1 0 0
      20837 1.5 1  8 3 5 4  36136 5 4    .03439737299999998  0    0 -1  0 0 0
      21384 2.5 3  8 1 3 3  30312 2 4    .07863300620000002  0    0 -1 -1 0 0
      21461   1 1  7 3 5 2  16200 3 1   -.01621452799999995  0    0  0 -1 0 0
      22099 2.5 3  9 1 3 3  28216 2 1           .1182723108 -1    -2 -2  1 0 0
      22169   2 3 10 3 5 2  12960 1 1    .21932814110000004  0    0 -1  0 0 0
      22173 1.5 3 10 3 5 2  14915 2 2    .17345590269999994  0    0  0  0 0 0
      22208   1 1 10 3 5 2  21621 4 4    .06631181189999996  0    0  0  0 0 0
      22276 1.5 1  8 3 4 4  39723 4 5   -.07224058570000003  0    0  0  0 0 0
      22277   2 1  9 1 4 4  42912 4 4  -.023690697900000002  0    0 -3 -1 1 1
      22286 1.5 1  9 3 4 3  18733 2 3          -.0903700609  0    0  0  1 0 0
      22292 1.5 1  8 3 5 2  40805 5 4  -.051360422100000025  0    0  0  0 0 0
      22624   3 3  4 3 4 2   5570 1 1           .2034894268  0    1  0  0 0 0
      22657 1.5 3  8 1 4 5  50104 5 6           .1976074524  0    0 -2  0 0 0
      22996 1.5 1  8 3 5 4  39623 4 4   .018421948800000032  0    -1 -1  0 0 0
      23370 1.5 1 10 3 5 3  17017 2 4    .03011848149999999  0    0  0  0 0 0
      23490   1 1  7 3 5 4  33182 5 6   .058377492400000036  0    0 -1 -1 0 0
      23797 1.5 3 10 1 4 3  26923 3 3    .22530952969999996  0    0  0  0 1 1
      23821 1.5 3  7 3 5 2  12882 1 1           .1031448952  0    0 -1  0 0 0
      23823 1.5 3  9 1 5 2  20433 3 2    .11031819539999999  0    0 -1  1 0 0
      23865 1.5 3  7 3 5 4  30729 4 3    .16642373639999997  0    -1 -1  1 0 0
      24147 1.5 1  9 1 4 5 118971 5 4   -.07227866699999996  0    0 -1  0 0 0
      24149   1 1  9 3 5 2   8221 1 2   .054499405600000106  0    0  0  0 0 0
      24194 2.5 1  9 1 4 2  64863 4 4    .05234625819999994 -4    0 -2  1 1 1
      24382 1.5 3  7 1 5 2  15885 2 1   .028309438600000014 -1    0  1 -1 0 0
      24393   1 3  8 3 5 2  13675 2 3           .0902485825  0    0  0  0 0 0
      24616 1.5 1  7 3 5 2  30697 4 4    .04514561969999997  0    0  0  0 0 0
      24760   1 3  9 3 5 2  16204 3 2           .0333865049  0    0  0  0 0 0
      24764 2.8 3  8 1 3 3  26823 1 2    .05413399570000002  0    0  0  0 1 1
      24809 1.5 3  7 3 5 2  32510 4 4           .3977658759  0    0  0  0 0 0
      24853   2 2 10 1 4 3  52178 4 5   .012224403899999986  0    -1 -2  1 1 1
      25007   1 3  8 3 5 4  21629 4 5    .01364379830000001  0    0 -1 -1 0 0
      25930 1.5 1 10 3 5 4  35224 4 5   -.14977107579999993  0    0  0  0 0 0
      26048 1.5 2 10 3 5 4  51467 5 4           .0872631754  0    0 -2  0 0 0
      26349 1.5 1  9 3 5 3  40240 5 4    .06503842930000003  0    0 -1 -1 0 0
      27109   1 3 10 3 5 1  13450 2 3     .3149223199000001  0    0  0  0 0 0
      27114   1 3  8 3 5 2  19059 3 3     .3149223199000001  0    0  0  1 0 0
      27116 1.5 3  9 3 5 3  18764 2 3    .21139835090000003  0    0  0  1 0 0
      27123 1.5 3  9 3 4 3  24418 3 4           .1760941695  0    0  0  0 0 0
      27157 2.5 3  8 1 3 4  22368 1 1   .001315833200000005  0    0 -3  0 0 0
      27238 1.5 2  8 1 4 3  18218 3 1    1.2509426923999998  0    0  0  2 1 1
      27509   1 1  9 3 5 2  15746 3 4   .013370739399999998  0    0  0 -1 0 0
      27730 2.5 3  9 1 4 3  39036 3 4           .0369032842  0    0  0  0 1 1
      27734   2 3  7 3 4 3  19983 1 3           .0793298559  0    0 -1  2 0 0
      27739   1 3  9 3 5 2  22166 4 3    .02803539399999999  0    0  0  0 0 0
      27742 1.5 3  8 1 5 1  27892 3 3           .1195533093  0    0 -1  0 1 1
      27912   2 3  9 1 4 4  40713 4 4           .3740483096 -3    0 -1 -2 1 1
      27923 2.3 3  8 3 4 4  36107 3 3    .31065573160000004  0    0 -2 -1 0 0
      27947 1.5 3  9 3 5 2  25245 3 3           .0713423771  0    0  0  0 0 0
      28100 3.3 3  9 1 4 4  31605 1 3    .12572265629999999  0    -1 -4  1 0 0
      28362   1 2 10 3 5 4  39881 5 4           .0930995355  0    0 -1  0 0 0
      28441 1.5 2 10 1 4 4  53234 5 5    .07934686980000005 -1    0 -2  0 0 0
      28802   2 1  1 1 3 4  51331 4 4          -.1608327826  0    0 -2  1 0 0
      28859   1 1  8 3 5 4  16214 3 2    .08787324600000002  0    0 -1  1 0 0
      28992 1.5 3  7 3 5 5  65624 5 4   -.18916334349999997  0    0 -1  0 0 0
      29006 1.5 1 10 3 5 4  45992 5 6   -.04220086000000001  0    0 -1 -1 0 0
      29140 1.5 2 10 1 4 3  38549 4 3  -.029117032399999965 -1    0  1  1 0 0
      29678 1.5 3  8 3 5 3  19361 2 3    .02919737850000001  0    0  0  0 0 0
      29680 2.5 3  7 1 3 3  27380 2 1          -.0448891911 -1    0 -1  0 1 1
      29737 1.5 3 10 1 4 5  58076 5 4     .1600397897999999 -1    0 -2  0 0 0
      29742 2.5 3  8 1 4 2  52387 4 3    1.4287730202999998 -1    0 -1  1 0 0
      29798 1.5 2 10 3 5 2  31979 4 4           .0700521694  0    0  0  0 0 0
      29823 3.3 3 10 1 3 5  46977 2 1   .061198501299999986  0    1 -3 -1 1 1
      31092 2.8 1  9 1 3 4  52856 3 2  -.014890796599999978  0    0 -3  0 0 0
      31093   1 1  9 2 4 4  31874 5 3  -.019213289900000013  0    0 -1  0 0 0
      31219   1 3  7 3 5 3  11579 2 3   .053378700400000006  0    0  0  0 0 0
      31220 1.5 1  7 3 5 2  66792 5 5            .208867438  0    0  0  0 0 0
      31221 1.5 1  6 3 5 4  41023 5 4           .3256287898  0    0 -1  0 0 0
      31246 1.5 1  8 3 5 2  31767 4 2          -.2720422723  0    0  0  1 0 0
      31304 1.5 2  8 3 5 4  37776 4 4    .22671147989999996  0    0 -2  0 0 0
      31448   1 1  9 3 5 4  39551 5 4    .03778809150000001  0    0 -1  0 0 0
      31625 1.5 1  9 1 5 2  46283 5 5    .08856968170000001  0    0 -1  0 0 0
      31652 1.5 1  9 3 5 4  48469 5 4    .05361615790000007  0    0 -2  0 0 0
      31665 1.5 1  8 3 5 4  23916 3 1   -.14245603839999998  0    0 -1 -1 0 0
      31671   1 1  8 3 4 3  30656 5 4   -.15834107800000002  0    0  0  0 0 0
      31695 2.5 1  6 1 2 3  75758 5 3    .11105999560000002 -2    0 -1 -1 0 0
      31724 2.8 1  9 1 1 4  68850 4 3          -.2613536927 -1    0 -3  0 1 1
      31757   1 1  9 3 5 4  17009 3 4    .12234858910000002  0    0 -1 -1 0 0
      31799 1.5 1  8 3 4 2  34664 4 4    .10384738099999996  0    0  1  0 0 0
      31860   2 3 10 1 3 3  43608 4 4    .09311158930000002 -1    0 -2  0 1 1
      31912 1.5 1  9 3 5 2  25243 3 4    -.0822802573000001  0    0  0  0 0 0
      32001 1.5 1  1 3 5 4  30165 4 3  -.028340982999999986  0    0 -1 -1 0 0
      32034 1.5 1  8 3 5 3  19862 2 3 -.0077776999999998875  0    0  1  0 0 0
      32044   1 1  8 3 5 2  16979 3 3          -.8299321136  0    0  0 -2 0 0
      32052 1.5 1  8 3 5 3  33089 4 3   -.03516808770000002  0    0  0  0 0 0
      32057   2 1  8 2 3 5  54543 5 4           .6522515157  0    0 -2 -2 0 0
      end
      I want to measure the effects of the so-called "80 euro tax rebate" on italian households consumption in 2014 (the "80 euro bonus" was given by Italian Government in may 2014).
      In order to do that, Neri et al. (2017) compare the change in spending, between 2012 and 2014, for households that received the bonus with the change in expenditure for those that did not receive it but were otherwise similar.
      The comparison group (non-recipient households) is chosen using propensity score matching: this is intended to ensure that those in the comparison group who do not receive the payment have characteristics similar to those of the payment recipients.
      To minimize the selection issue driven by observable pre-treatment disparities (that is, the potential effect of X on the outcomes), they compare eligible (D=1) and non-eligible (D=0) households that display strong similarities before the start of the program (in 2012). This is accomplished by using propensity score matching (PSM).

      The propensity score is estimated for each households using a probit model: P(Di=1 / xi)= f (xi'b)

      where Di takes the value one if the household is in the treatment group and zero otherwise and xi is a vector of household characteristics.


      The household characteristics are:

      -nocomp= number of components in the household
      -geoarea= geographical area in which the household live (1= Nord; 2= Centre; 3= South)
      -quaresponse= evalutation of the quality of the interview (from 1 to 10)
      -empact= employment activity (1= employee; 2= independent; 3= unemployed)
      -ageclass= (1 if age<34, 2 if age is between 34-45, ecc)
      ecc

      In other words, they include a number of variables to control for the probability of receiving the bonus, the demographic characteristics and general economic conditions of the household.


      NQUEST= first column (173,375, ecc): is the number of the household. All the household displayed above are the panel one.

      Comment


      • #4
        Here the excel file of dataset.
        Attached Files

        Comment


        • #5
          Thanks for the additional information & dataset Gabriele.

          A few remarks:
          • There are other PSM commands in Stata in addition to -psmatch2-, including the official command. Google "Stata propensity score matching" would get you plenty of useful links.
          • I made assumptions below as to which variables are your outcome & control variables - please double check & decide which one should be treated with the factor notation.
          • Furthermore, the interpretation is unclear to as most of your variables are nominal/categorical in nature without -label define-. Check especifically if the outcome variable is coded correctly.
          Code:
          version 15
          
          . clear all
          
          . import excel "/Users/.../DATASET_statalist22032020.xlsx", sheet("DATASET") firstrow
          
          . /* treatement variable */
          . tabulate bonus
          
                bonus |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    0 |      3,595       80.62       80.62
                    1 |        864       19.38      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          . /* control variables - assume to be pre-treatment values */
          . tab1 NoofComponentsEquiv Geographicalarea Qualityofincomeresponse Employmentactivity Ageclass Educationlevel Income Makeendsmeet 
          
          -> tabulation of NoofComponentsEquiv  
          
                No of |
           Components |
              (Equiv) |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |      1,118       25.07       25.07
                  1.3 |         16        0.36       25.43
                  1.5 |      1,372       30.77       56.20
                  1.6 |         11        0.25       56.45
                  1.8 |        188        4.22       60.66
                    2 |        686       15.38       76.05
                  2.1 |        235        5.27       81.32
                  2.3 |        140        3.14       84.46
                  2.4 |         43        0.96       85.42
                  2.5 |        410        9.19       94.62
                  2.6 |         35        0.78       95.40
                  2.7 |          4        0.09       95.49
                  2.8 |         59        1.32       96.82
                  2.9 |          7        0.16       96.97
                    3 |         78        1.75       98.72
                  3.1 |         13        0.29       99.01
                  3.3 |         22        0.49       99.51
                  3.4 |          1        0.02       99.53
                  3.5 |         16        0.36       99.89
                  3.6 |          1        0.02       99.91
                  3.8 |          3        0.07       99.98
                  4.4 |          1        0.02      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Geographicalarea  
          
          Geographica |
               l area |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |      1,855       41.60       41.60
                    2 |        876       19.65       61.25
                    3 |      1,728       38.75      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Qualityofincomeresponse  
          
           Quality of |
               income |
             response |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |         16        0.36        0.36
                    2 |         15        0.34        0.70
                    3 |         13        0.29        0.99
                    4 |         39        0.87        1.86
                    5 |        141        3.16        5.02
                    6 |        395        8.86       13.89
                    7 |        580       13.01       26.90
                    8 |        992       22.25       49.15
                    9 |      1,216       27.28       76.42
                   10 |      1,051       23.58      100.00
          ------------+-----------------------------------
                Total |      4,458      100.00
          
          -> tabulation of Employmentactivity  
          
           Employment |
             activity |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |      2,218       49.74       49.74
                    2 |        289        6.48       56.22
                    3 |      1,952       43.78      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Ageclass  
          
            Age class |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |        230        5.16        5.16
                    2 |        602       13.50       18.66
                    3 |        952       21.35       40.01
                    4 |        946       21.22       61.22
                    5 |      1,729       38.78      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Educationlevel  
          
            Education |
                level |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |        169        3.79        3.79
                    2 |        963       21.60       25.39
                    3 |      1,259       28.24       53.62
                    4 |      1,521       34.11       87.73
                    5 |        547       12.27      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Income  
          
               Income |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |        891       19.98       19.98
                    2 |        892       20.00       39.99
                    3 |        894       20.05       60.04
                    4 |        890       19.96       80.00
                    5 |        892       20.00      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          -> tabulation of Makeendsmeet  
          
            Make ends |
                 meet |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                    1 |        841       18.86       18.86
                    2 |        710       15.92       34.78
                    3 |      1,339       30.03       64.81
                    4 |      1,183       26.53       91.34
                    5 |        286        6.41       97.76
                    6 |        100        2.24      100.00
          ------------+-----------------------------------
                Total |      4,459      100.00
          
          . summarize Freecash 
          
              Variable |        Obs        Mean    Std. Dev.       Min        Max
          -------------+---------------------------------------------------------
              Freecash |      4,459    31907.88    23874.58      -3279     368689
          
          . local xlist "NoofComponentsEquiv Geographicalarea Qualityofincomeresponse Employmentactivity Ageclass Educationlevel Freecash Income Makeendsmeet"
          
          . /* outcome variable */
          . tabulate Deltaincomeafterbonus
          
                Delta |
               income |
          after bonus |      Freq.     Percent        Cum.
          ------------+-----------------------------------
                   -4 |          4        0.09        0.09
                   -3 |         18        0.40        0.49
                   -2 |        129        2.89        3.39
                   -1 |        712       15.96       19.35
            -.0004485 |          1        0.02       19.37
                    0 |      2,728       61.17       80.54
                    1 |        729       16.35       96.88
                    2 |        114        2.56       99.44
                    3 |         19        0.43       99.87
                    4 |          6        0.13      100.00
          ------------+-----------------------------------
                Total |      4,460      100.00
          
          . 
          . /* apply PSM using -psmatch2- */
          . 
          . /* basic syntax */
          . psmatch2 bonus `xlist', out(Deltaincomeafterbonus)
          
          Probit regression                               Number of obs     =      4,458
                                                          LR chi2(9)        =    1196.58
                                                          Prob > chi2       =     0.0000
          Log likelihood = -1593.7059                     Pseudo R2         =     0.2729
          
          -----------------------------------------------------------------------------------------
                            bonus |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
          ------------------------+----------------------------------------------------------------
              NoofComponentsEquiv |   .2892278   .0609726     4.74   0.000     .1697236    .4087319
                 Geographicalarea |  -.1299508   .0309123    -4.20   0.000    -.1905377   -.0693639
          Qualityofincomeresponse |   .0089886   .0168991     0.53   0.595    -.0241331    .0421103
               Employmentactivity |  -.8849035   .0477147   -18.55   0.000    -.9784226   -.7913844
                         Ageclass |    -.17563   .0264597    -6.64   0.000      -.22749     -.12377
                   Educationlevel |  -.0834041   .0337359    -2.47   0.013    -.1495252   -.0172831
                         Freecash |  -8.11e-06   2.34e-06    -3.47   0.001    -.0000127   -3.53e-06
                           Income |   .0973844   .0370513     2.63   0.009     .0247652    .1700036
                     Makeendsmeet |  -.0485061    .028253    -1.72   0.086     -.103881    .0068688
                            _cons |   1.130108   .2578115     4.38   0.000     .6248065    1.635409
          -----------------------------------------------------------------------------------------
          ----------------------------------------------------------------------------------------
                  Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
          ----------------------------+-----------------------------------------------------------
          Deltaincomeaft~s  Unmatched | .085648148  -.021146355   .106794503   .030556587     3.49
                                  ATT | .085648148      -.03125   .116898148   .047345672     2.47
          ----------------------------+-----------------------------------------------------------
          Note: S.E. does not take into account that the propensity score is estimated.
          
                     | psmatch2:
           psmatch2: |   Common
           Treatment |  support
          assignment | On suppor |     Total
          -----------+-----------+----------
           Untreated |     3,594 |     3,594 
             Treated |       864 |       864 
          -----------+-----------+----------
               Total |     4,458 |     4,458 
          
          . 
          . /* + common support */
          . psmatch2 bonus `xlist', out(Deltaincomeafterbonus) common
          
          Probit regression                               Number of obs     =      4,458
                                                          LR chi2(9)        =    1196.58
                                                          Prob > chi2       =     0.0000
          Log likelihood = -1593.7059                     Pseudo R2         =     0.2729
          
          -----------------------------------------------------------------------------------------
                            bonus |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
          ------------------------+----------------------------------------------------------------
              NoofComponentsEquiv |   .2892278   .0609726     4.74   0.000     .1697236    .4087319
                 Geographicalarea |  -.1299508   .0309123    -4.20   0.000    -.1905377   -.0693639
          Qualityofincomeresponse |   .0089886   .0168991     0.53   0.595    -.0241331    .0421103
               Employmentactivity |  -.8849035   .0477147   -18.55   0.000    -.9784226   -.7913844
                         Ageclass |    -.17563   .0264597    -6.64   0.000      -.22749     -.12377
                   Educationlevel |  -.0834041   .0337359    -2.47   0.013    -.1495252   -.0172831
                         Freecash |  -8.11e-06   2.34e-06    -3.47   0.001    -.0000127   -3.53e-06
                           Income |   .0973844   .0370513     2.63   0.009     .0247652    .1700036
                     Makeendsmeet |  -.0485061    .028253    -1.72   0.086     -.103881    .0068688
                            _cons |   1.130108   .2578115     4.38   0.000     .6248065    1.635409
          -----------------------------------------------------------------------------------------
          ----------------------------------------------------------------------------------------
                  Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
          ----------------------------+-----------------------------------------------------------
          Deltaincomeaft~s  Unmatched | .085648148  -.021146355   .106794503   .030556587     3.49
                                  ATT | .083526682  -.031322506   .114849188   .047394694     2.42
          ----------------------------+-----------------------------------------------------------
          Note: S.E. does not take into account that the propensity score is estimated.
          
           psmatch2: |   psmatch2: Common
           Treatment |        support
          assignment | Off suppo  On suppor |     Total
          -----------+----------------------+----------
           Untreated |         0      3,594 |     3,594 
             Treated |         2        862 |       864 
          -----------+----------------------+----------
               Total |         2      4,456 |     4,458 
          
          . 
          . /* + no replacement */
          . psmatch2 bonus `xlist', out(Deltaincomeafterbonus) common noreplacement
          
          Probit regression                               Number of obs     =      4,458
                                                          LR chi2(9)        =    1196.58
                                                          Prob > chi2       =     0.0000
          Log likelihood = -1593.7059                     Pseudo R2         =     0.2729
          
          -----------------------------------------------------------------------------------------
                            bonus |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
          ------------------------+----------------------------------------------------------------
              NoofComponentsEquiv |   .2892278   .0609726     4.74   0.000     .1697236    .4087319
                 Geographicalarea |  -.1299508   .0309123    -4.20   0.000    -.1905377   -.0693639
          Qualityofincomeresponse |   .0089886   .0168991     0.53   0.595    -.0241331    .0421103
               Employmentactivity |  -.8849035   .0477147   -18.55   0.000    -.9784226   -.7913844
                         Ageclass |    -.17563   .0264597    -6.64   0.000      -.22749     -.12377
                   Educationlevel |  -.0834041   .0337359    -2.47   0.013    -.1495252   -.0172831
                         Freecash |  -8.11e-06   2.34e-06    -3.47   0.001    -.0000127   -3.53e-06
                           Income |   .0973844   .0370513     2.63   0.009     .0247652    .1700036
                     Makeendsmeet |  -.0485061    .028253    -1.72   0.086     -.103881    .0068688
                            _cons |   1.130108   .2578115     4.38   0.000     .6248065    1.635409
          -----------------------------------------------------------------------------------------
          ----------------------------------------------------------------------------------------
                  Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
          ----------------------------+-----------------------------------------------------------
          Deltaincomeaft~s  Unmatched | .085648148  -.021146355   .106794503   .030556587     3.49
                                  ATT | .083526682  -.035962877   .119489559   .039258469     3.04
          ----------------------------+-----------------------------------------------------------
          Note: S.E. does not take into account that the propensity score is estimated.
          
           psmatch2: |   psmatch2: Common
           Treatment |        support
          assignment | Off suppo  On suppor |     Total
          -----------+----------------------+----------
           Untreated |         0      3,594 |     3,594 
             Treated |         2        862 |       864 
          -----------+----------------------+----------
               Total |         2      4,456 |     4,458 
          
          . 
          . /* + caliper set to 0.01 */
          . psmatch2 bonus `xlist', out(Deltaincomeafterbonus) common noreplacement caliper(0.01)
          
          Probit regression                               Number of obs     =      4,458
                                                          LR chi2(9)        =    1196.58
                                                          Prob > chi2       =     0.0000
          Log likelihood = -1593.7059                     Pseudo R2         =     0.2729
          
          -----------------------------------------------------------------------------------------
                            bonus |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
          ------------------------+----------------------------------------------------------------
              NoofComponentsEquiv |   .2892278   .0609726     4.74   0.000     .1697236    .4087319
                 Geographicalarea |  -.1299508   .0309123    -4.20   0.000    -.1905377   -.0693639
          Qualityofincomeresponse |   .0089886   .0168991     0.53   0.595    -.0241331    .0421103
               Employmentactivity |  -.8849035   .0477147   -18.55   0.000    -.9784226   -.7913844
                         Ageclass |    -.17563   .0264597    -6.64   0.000      -.22749     -.12377
                   Educationlevel |  -.0834041   .0337359    -2.47   0.013    -.1495252   -.0172831
                         Freecash |  -8.11e-06   2.34e-06    -3.47   0.001    -.0000127   -3.53e-06
                           Income |   .0973844   .0370513     2.63   0.009     .0247652    .1700036
                     Makeendsmeet |  -.0485061    .028253    -1.72   0.086     -.103881    .0068688
                            _cons |   1.130108   .2578115     4.38   0.000     .6248065    1.635409
          -----------------------------------------------------------------------------------------
          ----------------------------------------------------------------------------------------
                  Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
          ----------------------------+-----------------------------------------------------------
          Deltaincomeaft~s  Unmatched | .085648148  -.021146355   .106794503   .030556587     3.49
                                  ATT | .094951923  -.036057692   .131009615   .040075679     3.27
          ----------------------------+-----------------------------------------------------------
          Note: S.E. does not take into account that the propensity score is estimated.
          
           psmatch2: |   psmatch2: Common
           Treatment |        support
          assignment | Off suppo  On suppor |     Total
          -----------+----------------------+----------
           Untreated |         0      3,594 |     3,594 
             Treated |        32        832 |       864 
          -----------+----------------------+----------
               Total |        32      4,426 |     4,458 
          
          . 
          . /* + nearest neighbour set to 1 */
          . psmatch2 bonus `xlist', out(Deltaincomeafterbonus) common noreplacement caliper(0.01) neighbor(1)
          
          Probit regression                               Number of obs     =      4,458
                                                          LR chi2(9)        =    1196.58
                                                          Prob > chi2       =     0.0000
          Log likelihood = -1593.7059                     Pseudo R2         =     0.2729
          
          -----------------------------------------------------------------------------------------
                            bonus |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
          ------------------------+----------------------------------------------------------------
              NoofComponentsEquiv |   .2892278   .0609726     4.74   0.000     .1697236    .4087319
                 Geographicalarea |  -.1299508   .0309123    -4.20   0.000    -.1905377   -.0693639
          Qualityofincomeresponse |   .0089886   .0168991     0.53   0.595    -.0241331    .0421103
               Employmentactivity |  -.8849035   .0477147   -18.55   0.000    -.9784226   -.7913844
                         Ageclass |    -.17563   .0264597    -6.64   0.000      -.22749     -.12377
                   Educationlevel |  -.0834041   .0337359    -2.47   0.013    -.1495252   -.0172831
                         Freecash |  -8.11e-06   2.34e-06    -3.47   0.001    -.0000127   -3.53e-06
                           Income |   .0973844   .0370513     2.63   0.009     .0247652    .1700036
                     Makeendsmeet |  -.0485061    .028253    -1.72   0.086     -.103881    .0068688
                            _cons |   1.130108   .2578115     4.38   0.000     .6248065    1.635409
          -----------------------------------------------------------------------------------------
          ----------------------------------------------------------------------------------------
                  Variable     Sample |    Treated     Controls   Difference         S.E.   T-stat
          ----------------------------+-----------------------------------------------------------
          Deltaincomeaft~s  Unmatched | .085648148  -.021146355   .106794503   .030556587     3.49
                                  ATT | .094951923  -.036057692   .131009615   .040075679     3.27
          ----------------------------+-----------------------------------------------------------
          Note: S.E. does not take into account that the propensity score is estimated.
          
           psmatch2: |   psmatch2: Common
           Treatment |        support
          assignment | Off suppo  On suppor |     Total
          -----------+----------------------+----------
           Untreated |         0      3,594 |     3,594 
             Treated |        32        832 |       864 
          -----------+----------------------+----------
               Total |        32      4,426 |     4,458 
          
          . 
          . /* evaluate graphically */
          . psgraph
          
          . 
          . /* evaluate statistically */
          . pstest `xlist'
          
          -------------------------------------------------------------------------------
                                   |       Mean               |     t-test    |  V(T)/
          Variable                 | Treated Control    %bias |    t    p>|t| |  V(C)
          -------------------------+--------------------------+---------------+----------
          NoofComponentsEquiv      | 1.9614   1.9547      1.2 |   0.25  0.806 |  0.89
          Geographicalarea         | 1.8798   1.8834     -0.4 |  -0.08  0.934 |  0.93
          Qualityofincomeresponse  |  8.381   8.2488      8.6 |   1.78  0.076 |  0.93
          Employmentactivity       | 1.0721   1.0733     -0.2 |  -0.07  0.945 |  1.07
          Ageclass                 | 2.9207   2.9435     -2.0 |  -0.42  0.674 |  0.96
          Educationlevel           | 3.5974   3.5264      7.3 |   1.68  0.093 |  0.88
          Freecash                 |  34052    32869      5.4 |   1.26  0.208 |  0.87*
          Income                   | 2.9832   2.9038      5.8 |   1.18  0.239 |  0.84*
          Makeendsmeet             | 2.8774   2.7776      8.1 |   1.67  0.095 |  0.84*
          -------------------------------------------------------------------------------
          * if variance ratio outside [0.87; 1.15]
          
          ----------------------------------------------------------------------
          Ps R2   LR chi2   p>chi2   MeanBias   MedBias      B       R     %Var 
          ----------------------------------------------------------------------
          0.003      7.31    0.605      4.3       5.4      13.3    0.90      33
          ----------------------------------------------------------------------
          * if B>25%, R outside [0.5; 2]

          Comment


          • #6
            Junran Cao, forgive me but I have a very little theoric knowledge of PSM.

            I have two questions for you:

            1) I typed the following commands to generate the dummy variable on Stata:

            /* generating the dummy variable */

            . generate eligible=0

            . replace eligible=1 if bonus==1
            (864 real changes made)

            Is that procedure right?

            2) Neri et al. (2017) find that, as a result of the PSM, the sample includes 785 treated and 785 control households, both in 2012 and 2014.
            Please find the attached, in which they reported the mean and the sd for the treated and control groups for each of the explanatory variables.

            Which command shall I do in order to obtain exaclty these results?
            Attached Files

            Comment


            • #7
              1) Yes, that would work. For a comprehensive review of all the different ways we can generate indicator variables, see

              Cox, Nicholas J., and Clyde B. Schechter. 2019. ‘Speaking Stata: How Best to Generate Indicator or Dummy Variables’. The Stata Journal: Promoting Communications on Statistics and Stata 19 (1): 246–59. https://doi.org/10.1177/1536867X19830921.

              2) To replicate the table, you would need to include the same set of control variables as Neri et al. (2017). I only selected a number of control variables that I interpreted to be pre-treatment characteristics as an illustration.

              Where there is X1 X2 X3 below, type in the full list of control variables separated by a space
              Code:
              psmatch2 bonus X1 X2 X3, out(Deltaincomeafterbonus) common noreplacement caliper(0.01) neighbor(1)
              
              pstest X1 X2 X3
              If you just look at the mean values for the Treated and Control, are you getting the same/similar values to Neri et al. (2017)?

              Comment


              • #8
                Ok now I'll try the command, I think I got it, but I don't understand completely yet.

                I don't understand why you have put the variable Deltaincomeafterbonus into the outcome().

                Should I put each variable into the outcome()?

                Comment


                • #9
                  At any rate, I do exactly your command: the only change that I made is that I put the dummy eligible instead of bonus.
                  That's the result.

                  Attached Files

                  Comment


                  • #10
                    Here the mean values:
                    Attached Files

                    Comment


                    • #11
                      The results shows that the number of treated and control household is very different from the Neri et al.'s one ( in which there are 785 treated and 785 control households).

                      Nevertheless, I think the probit regression that you suggest me it's right, so I don't understand.

                      Comment


                      • #12
                        Gabriele:

                        I think it'd be advisable to take a step back and proceed in a methodical manner:

                        First, as you are new to PSM, it is important to at least gain an intuitive understanding of what PSM does. There is a wealth of information online but if you are really pressed for time, then at least watch the first two videos in this series https://www.youtube.com/watch?v=-0HV...RKfWZFc5E5tdSg

                        Second, let's understand how PSM is implemented in Stata. As I mentioned previously, there are quite a few Stata commands on PSM but let's focus on -psmatch2- for now. https://www.youtube.com/watch?v=7RT8zFC5Rac is a good place to start (but definitely read the help file as well). Here you'll see that you need: a) an indicator variable to indicate which household is in the Treated group & which is in the Control group b) a list of control variables representing pre-treatment characteristics. Here you'd refer to Neri et al (2017)'s list of control variables c) an outcome variable. This is the variable that represents "the change in spending between 2012 and 2014". My assumption was that -Deltaincomeafterbonus- is the outcome variable but I cannot of course be sure.

                        Third, use -codebook- and -summarize- and -tabulate- to check that each of the variable contains the values you expect. The majority of your variables seem to be ordinal/categorical and so you'd need to understand what "-1, 0 , 1, 2 ..." refers to. Also make sure there are no coding errors: if you run -tabulate Deltaincomeafterbonus-, you'll see the values for this variable are perhaps not correct.

                        Fourth, now you are ready to place the indicator & outcome & control variables into -psmatch2-. In my initial answer, I added the options (e.g. common support, without replacement, etc.) one at a time. Experiment with these to see which combination makes the most sense for your study.

                        Comment


                        • #13
                          Junran,

                          thanks a lot indeed.

                          Ok, at the end, with your help, I have understood what the part outcome() means.

                          Whatever the variable I put into outcome(), I have got, in terms of number of treated and untreated, the same results that I posted in reply number 12.

                          Why?

                          Comment


                          • #14
                            *errata corrige: reply numer 9.

                            Comment


                            • #15
                              Sorry Junran,

                              I think I have understood what I have to do.

                              Here it is the indication of Neri et al.: "To estimate the marginal propensity to consume out of the scal stimulus we compare the change in spending for households that received the payment with the change in expenditure for those that did not receive it but were otherwise similar."

                              Since in the overall Bank of Italy dataset (that I haven't shown to you completely), the variables consumption 2012 and consumption 2014 exist, shall I put as outcome variable the difference between them?

                              Comment

                              Working...
                              X