Announcement

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

  • compare the coefficients of the independent variable between two subgroup regressions

    Hi again,

    I'm encountering a problem using -chowtest-. I'm running two xtreg regressions with firm and year F.E., one subsample with high dummy ==1, the other with high dummy ==0. I'm using -chowtest- because -suest- doesn't support -xtreg-, so I can't use -test- or -lincom- afterwards.
    Code:
    chowtest y x cotrols i.firm i.year, group(high)
    I get the following error message
    Code:
    maxvar too small
        You have attempted to use an interaction with too many levels or attempted to fit a model with too
        many variables.  You need to increase maxvar; it is currently 5000.  Use set maxvar; see help 
        maxvar.
    
        If you are using factor variables and included an interaction that has lots of missing cells, try
        set emptycells drop to reduce the required matrix size; see help set emptycells.
    
        If you are using factor variables, you might have accidentally treated a continuous variable as a
        categorical, resulting in lots of categories.  Use the c. operator on such variables.
    r(907);
    I think what stata means "too many levels" is that I control for firm F.E., and indeed if I delete i.firm, it works. With the two-way F.E. model, I need both firm and year F.E., I wonder what can I do to make it work? Thanks!

  • #2
    Alice:
    while it's true that -suest- does not support -xtreg, fe-, you may want to consider -sureg-, using -regress- with -i.panelvar- and -i.year- in addition to ther predictors and invoking -cluster()- just before typing -sureg-:
    Code:
    use "https://www.stata-press.com/data/r17/nlswork.dta"
    . regress ln_wage i.idcode i.year c.age##c.age if idcode<=20 & nev_mar==0 & year>=70
    
          Source |       SS           df       MS      Number of obs   =       131
    -------------+----------------------------------   F(30, 100)      =      7.75
           Model |  17.9319848        30  .597732825   Prob > F        =    0.0000
        Residual |  7.71722779       100  .077172278   R-squared       =    0.6991
    -------------+----------------------------------   Adj R-squared   =    0.6089
           Total |  25.6492125       130  .197301635   Root MSE        =     .2778
    
    ------------------------------------------------------------------------------
         ln_wage | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
    -------------+----------------------------------------------------------------
          idcode |
              2  |  -.3985991   .1162129    -3.43   0.001    -.6291622   -.1680361
              4  |  -2.153039   .8993956    -2.39   0.019    -3.937414    -.368664
              5  |  -2.115848   .9026901    -2.34   0.021     -3.90676   -.3249368
              6  |  -1.949703    .748923    -2.60   0.011    -3.435545   -.4638616
              7  |  -1.601565    .398199    -4.02   0.000    -2.391581   -.8115498
              9  |   .0267441   .1231572     0.22   0.829    -.2175963    .2710845
             10  |  -.7165237   .1445676    -4.96   0.000    -1.003342   -.4297056
             12  |  -.5660006   .5844716    -0.97   0.335    -1.725576    .5935743
             13  |  -1.197846   .5912625    -2.03   0.045    -2.370894   -.0247985
             14  |  -1.393738   .5844716    -2.38   0.019    -2.553313   -.2341635
             15  |  -.6671047   .4498168    -1.48   0.141    -1.559528     .225319
             16  |  -.9542889   .4674196    -2.04   0.044    -1.881636   -.0269416
             17  |  -.8061581   .4731089    -1.70   0.091    -1.744793    .1324766
             18  |  -1.761373   .4848091    -3.63   0.000     -2.72322   -.7995251
             19  |  -1.198246   .4639306    -2.58   0.011    -2.118671   -.2778205
             20  |  -1.057955   .4505725    -2.35   0.021    -1.951878   -.1640323
                 |
            year |
             71  |  -.3846318   .2400682    -1.60   0.112    -.8609202    .0916566
             72  |  -.6422765   .3389681    -1.89   0.061     -1.31478    .0302266
             73  |  -.9147847   .4531278    -2.02   0.046    -1.813777   -.0157921
             75  |  -1.637065    .744296    -2.20   0.030    -3.113727    -.160403
             77  |  -2.468558   1.034075    -2.39   0.019    -4.520133   -.4169825
             78  |  -2.718327   1.182146    -2.30   0.024    -5.063671   -.3729843
             80  |  -3.497179   1.475272    -2.37   0.020    -6.424078    -.570281
             82  |   -4.19537   1.769693    -2.37   0.020    -7.706391     -.68435
             83  |  -4.282855   1.916492    -2.23   0.028     -8.08512   -.4805904
             85  |  -4.744166   2.209252    -2.15   0.034    -9.127259   -.3610736
             87  |  -5.472591   2.504624    -2.18   0.031    -10.44169    -.503488
             88  |  -5.770168   2.746684    -2.10   0.038    -11.21951    -.320824
                 |
             age |   .5584909   .1664175     3.36   0.001     .2283232    .8886585
                 |
     c.age#c.age |  -.0036283   .0011315    -3.21   0.002    -.0058731   -.0013835
                 |
           _cons |  -7.288003   2.913776    -2.50   0.014    -13.06885   -1.507155
    ------------------------------------------------------------------------------
    
    . est store model1
    
    . regress ln_wage i.idcode i.year c.age##c.age if idcode<=20 & nev_mar==1 & year>=70
    note: age omitted because of collinearity.
    
          Source |       SS           df       MS      Number of obs   =        37
    -------------+----------------------------------   F(22, 14)       =     14.33
           Model |  1.92554289        22  .087524677   Prob > F        =    0.0000
        Residual |  .085521053        14  .006108647   R-squared       =    0.9575
    -------------+----------------------------------   Adj R-squared   =    0.8906
           Total |  2.01106394        36  .055862887   Root MSE        =    .07816
    
    ------------------------------------------------------------------------------
         ln_wage | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
    -------------+----------------------------------------------------------------
          idcode |
              3  |   .2483247   .8863086     0.28   0.783    -1.652618    2.149268
              4  |    1.02995   .8623204     1.19   0.252    -.8195433    2.879443
              5  |   .5474355   .8863086     0.62   0.547    -1.353507    2.448378
              9  |   .1263577   .0960831     1.32   0.210      -.07972    .3324354
             10  |   .0511744   .0982263     0.52   0.611    -.1595002    .2618489
             16  |   .5789633   .3893933     1.49   0.159    -.2562023    1.414129
             17  |   .5835921   .4089031     1.43   0.175    -.2934178    1.460602
             19  |   .6367364   .4089031     1.56   0.142    -.2402735    1.513746
             20  |   .6474642   .4059241     1.60   0.133    -.2231565    1.518085
                 |
            year |
             71  |   .0966576   .1510702     0.64   0.533    -.2273557    .4206709
             72  |   .1935223    .308364     0.63   0.540    -.4678528    .8548974
             73  |   .2529087   .4907068     0.52   0.614    -.7995526     1.30537
             75  |   .0950733   .8557801     0.11   0.913    -1.740392    1.930539
             77  |   .4103127    1.28329     0.32   0.754     -2.34207    3.162695
             78  |   .4022728   1.496635     0.27   0.792     -2.80769    3.612236
             80  |   .4962802    1.94397     0.26   0.802    -3.673121    4.665681
             82  |   .6470116   2.418671     0.27   0.793    -4.540522    5.834545
             83  |    .713633   2.666252     0.27   0.793     -5.00491    6.432176
             85  |   .9464119   3.181843     0.30   0.770    -5.877962    7.770786
             87  |   .8637048   3.724644     0.23   0.820    -7.124861    8.852271
             88  |   1.014173   4.006242     0.25   0.804    -7.578361    9.606707
                 |
             age |          0  (omitted)
                 |
     c.age#c.age |  -.0007645   .0033937    -0.23   0.825    -.0080433    .0065142
                 |
           _cons |   1.698924   1.102326     1.54   0.146    -.6653304    4.063179
    ------------------------------------------------------------------------------
    
    . est store model2
    
    . suest model1 model2, cluster()
    
    Simultaneous results for model1, model2                    Number of obs = 168
    
    ------------------------------------------------------------------------------
                 |               Robust
                 | Coefficient  std. err.      z    P>|z|     [95% conf. interval]
    -------------+----------------------------------------------------------------
    model1_mean  |
          idcode |
              2  |  -.3985991   .1096519    -3.64   0.000     -.613513   -.1836853
              4  |  -2.153039    1.05238    -2.05   0.041    -4.215666   -.0904124
              5  |  -2.115848    1.03228    -2.05   0.040     -4.13908   -.0926169
              6  |  -1.949703   .8678963    -2.25   0.025    -3.650749   -.2486579
              7  |  -1.601565   .5637183    -2.84   0.004    -2.706433   -.4966976
              9  |   .0267441   .1029155     0.26   0.795    -.1749666    .2284548
             10  |  -.7165237   .1376904    -5.20   0.000    -.9863919   -.4466555
             12  |  -.5660006   .6201784    -0.91   0.361    -1.781528    .6495267
             13  |  -1.197846    .675193    -1.77   0.076      -2.5212    .1255074
             14  |  -1.393738   .6189753    -2.25   0.024    -2.606908   -.1805692
             15  |  -.6671047    .510464    -1.31   0.191    -1.667596    .3333862
             16  |  -.9542889   .5254206    -1.82   0.069    -1.984094    .0755166
             17  |  -.8061581   .5201381    -1.55   0.121     -1.82561    .2132939
             18  |  -1.761373   .5318271    -3.31   0.001    -2.803734   -.7190106
             19  |  -1.198246   .5243101    -2.29   0.022    -2.225874   -.1706167
             20  |  -1.057955   .5064651    -2.09   0.037    -2.050609   -.0653019
                 |
            year |
             71  |  -.3846318   .2663293    -1.44   0.149    -.9066277     .137364
             72  |  -.6422765   .3893245    -1.65   0.099    -1.405339    .1207856
             73  |  -.9147847   .5399805    -1.69   0.090    -1.973127    .1435576
             75  |  -1.637065   .8949692    -1.83   0.067    -3.391172    .1170422
             77  |  -2.468558   1.240131    -1.99   0.047    -4.899169   -.0379463
             78  |  -2.718327   1.415795    -1.92   0.055    -5.493234    .0565792
             80  |  -3.497179   1.761567    -1.99   0.047    -6.949787   -.0445724
             82  |   -4.19537   2.107863    -1.99   0.047    -8.326705   -.0640354
             83  |  -4.282855   2.278382    -1.88   0.060    -8.748402     .182691
             85  |  -4.744166   2.609252    -1.82   0.069    -9.858206     .369873
             87  |  -5.472591   3.005303    -1.82   0.069    -11.36288    .4176946
             88  |  -5.770168   3.246711    -1.78   0.076     -12.1336    .5932698
                 |
             age |   .5584909   .1880901     2.97   0.003      .189841    .9271407
                 |
     c.age#c.age |  -.0036283   .0011017    -3.29   0.001    -.0057877    -.001469
                 |
           _cons |  -7.288003   3.300552    -2.21   0.027    -13.75697   -.8190393
    -------------+----------------------------------------------------------------
    model1_lnvar |
           _cons |  -2.561715   .1597886   -16.03   0.000    -2.874895   -2.248535
    -------------+----------------------------------------------------------------
    model2_mean  |
          idcode |
              3  |   .2483247   .7219233     0.34   0.731    -1.166619    1.663268
              4  |    1.02995   .7106266     1.45   0.147    -.3628526    2.422752
              5  |   .5474355   .7220786     0.76   0.448    -.8678126    1.962684
              9  |   .1263577   .0629834     2.01   0.045     .0029125    .2498029
             10  |   .0511744   .0339501     1.51   0.132    -.0153667    .1177154
             16  |   .5789633   .3086062     1.88   0.061    -.0258937     1.18382
             17  |   .5835921   .3278443     1.78   0.075    -.0589709    1.226155
             19  |   .6367364   .3258607     1.95   0.051    -.0019389    1.275412
             20  |   .6474642   .3222265     2.01   0.045     .0159119    1.279017
                 |
            year |
             71  |   .0966576   .1326032     0.73   0.466    -.1632399    .3565551
             72  |   .1935223   .2654824     0.73   0.466    -.3268137    .7138583
             73  |   .2529087    .415236     0.61   0.542     -.560939    1.066756
             75  |   .0950733   .6845416     0.14   0.890    -1.246604     1.43675
             77  |   .4103127   1.075616     0.38   0.703    -1.697857    2.518482
             78  |   .4022728   1.253203     0.32   0.748     -2.05396    2.858505
             80  |   .4962802   1.625338     0.31   0.760    -2.689325    3.681885
             82  |   .6470116   2.020067     0.32   0.749    -3.312247     4.60627
             83  |    .713633   2.225899     0.32   0.749    -3.649048    5.076314
             85  |   .9464119   2.654492     0.36   0.721    -4.256297     6.14912
             87  |   .8637048   3.105654     0.28   0.781    -5.223266    6.950675
             88  |   1.014173   3.339698     0.30   0.761    -5.531514     7.55986
                 |
             age |          0  (omitted)
                 |
     c.age#c.age |  -.0007645   .0028199    -0.27   0.786    -.0062915    .0047625
                 |
           _cons |   1.698924   .9136627     1.86   0.063    -.0918218     3.48967
    -------------+----------------------------------------------------------------
    model2_lnvar |
           _cons |   -5.09805   .1517883   -33.59   0.000     -5.39555    -4.80055
    ------------------------------------------------------------------------------
    
    
    . test [model1_mean]c.age#c.age=[model2_mean]c.age#c.age
    
     ( 1)  [model1_mean]c.age#c.age - [model2_mean]c.age#c.age = 0
    
               chi2(  1) =    0.89
             Prob > chi2 =    0.3442
    
    .
    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Hi Carlo,

      Thanks a lot for your help. I have a new problem now. My code
      Code:
      reg y i.x controls i.firm i.year if high==1
      est store model1
      
      reg y i.x controls i.firm i.year if high==0
      est store model2
      
      suest model1 model2, cluster()
      
      test [model1_mean]x = [model2_mean]x
      x is a dummy variable, so as high. Then I get this error message
      Code:
      firm: factor variable base category conflict
      r(198);
      Can you spot anything wrong here? Thanks!

      Comment


      • #4
        I have encountered this situation before. A trick is to clone the categorical variables that trigger the error and use the cloned variables in the second estimation. #2 of https://www.statalist.org/forums/for...t-time-periods illustrates.
        Last edited by Andrew Musau; 12 May 2022, 02:44.

        Comment


        • #5
          Hi Andrew,

          Thanks for your trick, it works well!

          Comment


          • #6
            hello again,

            It's been a while since I asked this question, I have another problem now. When I use the following code
            Code:
            reg y i.x controls i.firm i.year if high==1
            est store model1
            
            gen FIRM = firm
            
            reg y i.x controls i.FIRM i.year if high==0
            est store model2
            
            suest model1 model2, cluster()
            
            test [model1_mean]x = [model2_mean]x
            I got this error message
            Code:
            [x] not found
            r(111);
            If I use i.x, then
            Code:
            i:  operator invalid
            r(198);
            I don't know why x is not found, it is used in estimating model1 and model2, so what's wrong here? x is a dummy variable.

            Thanks a lot for any advice!

            Comment


            • #7
              Alice:
              I cannot replicate your problem:
              Code:
              . sysuse auto
              (1978 automobile data)
              
              
              . regress price mpg trunk if foreign==0
              
                    Source |       SS           df       MS      Number of obs   =        52
              -------------+----------------------------------   F(2, 49)        =      8.42
                     Model |   125089266         2    62544633   Prob > F        =    0.0007
                  Residual |   364105535        49   7430725.2   R-squared       =    0.2557
              -------------+----------------------------------   Adj R-squared   =    0.2253
                     Total |   489194801        51  9592054.92   Root MSE        =    2725.9
              
              ------------------------------------------------------------------------------
                     price | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
              -------------+----------------------------------------------------------------
                       mpg |   -307.292   107.8128    -2.85   0.006      -523.95   -90.63405
                     trunk |   36.35242   118.7538     0.31   0.761    -202.2924    274.9972
                     _cons |   11628.88   3572.654     3.25   0.002     4449.364     18808.4
              ------------------------------------------------------------------------------
              
              . estimate store foreign_0
              
              . regress price mpg trunk if foreign==1
              
                    Source |       SS           df       MS      Number of obs   =        22
              -------------+----------------------------------   F(2, 19)        =      7.30
                     Model |  62721024.2         2  31360512.1   Prob > F        =    0.0044
                  Residual |  81642188.6        19  4296957.29   R-squared       =    0.4345
              -------------+----------------------------------   Adj R-squared   =    0.3749
                     Total |   144363213        21   6874438.7   Root MSE        =    2072.9
              
              ------------------------------------------------------------------------------
                     price | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
              -------------+----------------------------------------------------------------
                       mpg |  -232.7421   70.27696    -3.31   0.004    -379.8335   -85.65075
                     trunk |   158.6694   144.4289     1.10   0.286    -143.6237    460.9625
                     _cons |   10340.07   2692.813     3.84   0.001     4703.943    15976.19
              ------------------------------------------------------------------------------
              
              . estimate store foreign_1
              
              . suest foreign_0 foreign_1 , cluster()
              
              Simultaneous results for foreign_0, foreign_1               Number of obs = 74
              
              ---------------------------------------------------------------------------------
                              |               Robust
                              | Coefficient  std. err.      z    P>|z|     [95% conf. interval]
              ----------------+----------------------------------------------------------------
              foreign_0_mean  |
                          mpg |   -307.292   111.5024    -2.76   0.006    -525.8328   -88.75125
                        trunk |   36.35242   89.39376     0.41   0.684    -138.8561     211.561
                        _cons |   11628.88   3479.299     3.34   0.001     4809.581    18448.18
              ----------------+----------------------------------------------------------------
              foreign_0_lnvar |
                        _cons |   15.82113   .2967708    53.31   0.000     15.23947    16.40279
              ----------------+----------------------------------------------------------------
              foreign_1_mean  |
                          mpg |  -232.7421   73.49488    -3.17   0.002    -376.7894   -88.69479
                        trunk |   158.6694   119.9163     1.32   0.186    -76.36216     393.701
                        _cons |   10340.07   2334.061     4.43   0.000     5765.389    14914.74
              ----------------+----------------------------------------------------------------
              foreign_1_lnvar |
                        _cons |   15.27342   .2284388    66.86   0.000     14.82569    15.72115
              ---------------------------------------------------------------------------------
              
              . test [foreign_0_mean]mpg = [foreign_1_mean]mpg
              
               ( 1)  [foreign_0_mean]mpg - [foreign_1_mean]mpg = 0
              
                         chi2(  1) =    0.31
                       Prob > chi2 =    0.5767
              
              .
              Kind regards,
              Carlo
              (Stata 19.0)

              Comment


              • #8
                is "x" an actual variable in your data or is, e.g., a local (which would call for slightly different syntax)

                Comment


                • #9
                  Alice:
                  as an aside to Rich's helpful insight, owing Andrew Musau so much as usual, I applied his astute trick while elaborating on my previous example:
                  Code:
                  . sysuse auto.dta
                  (1978 automobile data)
                  
                  . clonevar new_rep78=rep78
                  (5 missing values generated)
                  
                  .  regress price mpg trunk i.rep78 if foreign==0
                  
                        Source |       SS           df       MS      Number of obs   =        48
                  -------------+----------------------------------   F(6, 41)        =      3.13
                         Model |   150261808         6  25043634.7   Prob > F        =    0.0128
                      Residual |   327705889        41  7992826.55   R-squared       =    0.3144
                  -------------+----------------------------------   Adj R-squared   =    0.2140
                         Total |   477967697        47  10169525.5   Root MSE        =    2827.2
                  
                  ------------------------------------------------------------------------------
                         price | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
                  -------------+----------------------------------------------------------------
                           mpg |  -421.9874   133.0415    -3.17   0.003    -690.6701   -153.3046
                         trunk |   4.537399   137.4309     0.03   0.974    -273.0099    282.0847
                               |
                         rep78 |
                            2  |   584.1071   2346.868     0.25   0.805    -4155.489    5323.704
                            3  |   1166.417   2234.737     0.52   0.605    -3346.725     5679.56
                            4  |    201.588   2406.236     0.08   0.934    -4657.904     5061.08
                            5  |   4277.323   3225.064     1.33   0.192    -2235.824    10790.47
                               |
                         _cons |   13387.67   4145.464     3.23   0.002     5015.732     21759.6
                  ------------------------------------------------------------------------------
                  
                  . estimate store foreign_0
                  
                  .  regress price mpg trunk i.new_rep78 if foreign==1
                  
                        Source |       SS           df       MS      Number of obs   =        21
                  -------------+----------------------------------   F(4, 16)        =      3.28
                         Model |    44485047         4  11121261.8   Prob > F        =    0.0381
                      Residual |  54170307.5        16  3385644.22   R-squared       =    0.4509
                  -------------+----------------------------------   Adj R-squared   =    0.3136
                         Total |  98655354.6        20  4932767.73   Root MSE        =      1840
                  
                  ------------------------------------------------------------------------------
                         price | Coefficient  Std. err.      t    P>|t|     [95% conf. interval]
                  -------------+----------------------------------------------------------------
                           mpg |   -197.077   67.44553    -2.92   0.010    -340.0551   -54.09885
                         trunk |   151.8929   134.1417     1.13   0.274    -132.4748    436.2607
                               |
                     new_rep78 |
                            4  |   2043.128   1255.692     1.63   0.123    -618.8201    4705.076
                            5  |   2122.739   1242.792     1.71   0.107    -511.8621     4757.34
                               |
                         _cons |   7553.783   2712.066     2.79   0.013      1804.46    13303.11
                  ------------------------------------------------------------------------------
                  
                  . estimate store foreign_1
                  
                  . suest foreign_0 foreign_1, cluster()
                  
                  Simultaneous results for foreign_0, foreign_1               Number of obs = 69
                  
                  ---------------------------------------------------------------------------------
                                  |               Robust
                                  | Coefficient  std. err.      z    P>|z|     [95% conf. interval]
                  ----------------+----------------------------------------------------------------
                  foreign_0_mean  |
                              mpg |  -421.9874   126.1393    -3.35   0.001    -669.2159   -174.7588
                            trunk |   4.537399   103.6611     0.04   0.965    -198.6347    207.7095
                                  |
                            rep78 |
                               2  |   584.1071    1237.14     0.47   0.637    -1840.643    3008.858
                               3  |   1166.417   1165.787     1.00   0.317    -1118.484    3451.319
                               4  |    201.588   1080.791     0.19   0.852    -1916.724      2319.9
                               5  |   4277.323   1760.797     2.43   0.015     826.2246    7728.422
                                  |
                            _cons |   13387.67   3371.028     3.97   0.000     6780.573    19994.76
                  ----------------+----------------------------------------------------------------
                  foreign_0_lnvar |
                            _cons |   15.89406   .2851599    55.74   0.000     15.33515    16.45296
                  ----------------+----------------------------------------------------------------
                  foreign_1_mean  |
                              mpg |   -197.077   66.48022    -2.96   0.003    -327.3758   -66.77815
                            trunk |   151.8929   94.27177     1.61   0.107    -32.87633    336.6622
                                  |
                        new_rep78 |
                               4  |   2043.128   948.4507     2.15   0.031     184.1986    3902.057
                               5  |   2122.739   1040.569     2.04   0.041     83.26023    4162.218
                                  |
                            _cons |   7553.783   2156.595     3.50   0.000     3326.934    11780.63
                  ----------------+----------------------------------------------------------------
                  foreign_1_lnvar |
                            _cons |   15.03505   .2229259    67.44   0.000     14.59813    15.47198
                  ---------------------------------------------------------------------------------
                  
                  . test [foreign_0_mean]2.rep78 = [foreign_1_mean]4.new_rep78
                  
                   ( 1)  [foreign_0_mean]2.rep78 - [foreign_1_mean]4.new_rep78 = 0
                  
                             chi2(  1) =    0.88
                           Prob > chi2 =    0.3493
                  As far as your second error message is concerned, I tried to replicate it via:
                  Code:
                  . test [foreign_0_mean]i.rep78 = [foreign_1_mean]i.new_rep78
                  i:  operator invalid
                  r(198);
                  This error message makes sense as Stata cannot understand which levels of te categorical variable I'm going to compare.
                  Kind regards,
                  Carlo
                  (Stata 19.0)

                  Comment


                  • #10
                    Hi Carlo,

                    My bad... I've spelt the independent variable wrong, that's why stata says the variable is not found... For simplicity, I use x to represent the dummy independent variable, the actual variable is of another name. Sorry for causing any confusion, and thanks a lot for your help!

                    Comment

                    Working...
                    X