Announcement

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

  • Multilevel country differences.

    Dear all,

    I need to check if there are country differences in a given cross-sectional data for 15 countries.

    I need some help here please because I don't want the country dummies like this "Icountry_" but name of the countries.

    If I use the command tabulate I can see the country names. So how can I proceed? Best regards.


    . xi: regress l_currwage i.country if female==0
    i.country _Icountry_1-17 (naturally coded; _Icountry_1 omitted)

    Source | SS df MS Number of obs = 11,496
    -------------+---------------------------------- F(13, 11482) = 912.72
    Model | 3249.68573 13 249.975826 Prob > F = 0.0000
    Residual | 3144.68236 11,482 .273879321 R-squared = 0.5082
    -------------+---------------------------------- Adj R-squared = 0.5077
    Total | 6394.36809 11,495 .556273866 Root MSE = .52333

    ------------------------------------------------------------------------------
    l_currwage | Coef. Std. Err. t P>|t| [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    _Icountry_2 | -.1053162 .0233258 -4.51 0.000 -.1510388 -.0595935
    _Icountry_3 | .3190945 .0308593 10.34 0.000 .2586051 .3795839
    _Icountry_4 | .4828259 .0272102 17.74 0.000 .4294894 .5361625
    _Icountry_5 | .70259 .0266292 26.38 0.000 .6503921 .7547878
    _Icountry_6 | .4340455 .0235751 18.41 0.000 .3878342 .4802568
    _Icountry_7 | .4322194 .0290047 14.90 0.000 .3753652 .4890736
    _Icountry_8 | .4741311 .0256151 18.51 0.000 .4239211 .5243412
    _Icountry_10 | .8004014 .0261061 30.66 0.000 .7492289 .8515738
    _Icountry_11 | -.7822046 .0203266 -38.48 0.000 -.8220481 -.742361
    _Icountry_12 | .1948256 .0238843 8.16 0.000 .1480083 .2416429
    _Icountry_15 | -.1936727 .0400545 -4.84 0.000 -.2721862 -.1151591
    _Icountry_16 | .4679915 .0288625 16.21 0.000 .4114161 .524567
    _Icountry_17 | -.5484833 .0368746 -14.87 0.000 -.6207637 -.4762028
    _cons | 7.447691 .0175029 425.51 0.000 7.413382 7.481999











  • #2
    Self-inflicted wound. Don't use -xi:-. Rely on factor variable notation (see -help fvvarlist- for details). Factor variable notation has largely replaced -xi-. There are still a few official Stata commands, and perhaps a larger number of user-written commands, that do not support factor-variable notation. But they are mostly older commands whose functions are now available in newer commands that do support factor-variable notation. So while it's not yet time to forget you ever knew about -xi-, it should only be used after you have tried factor-variable notation and gotten an error message saying that it is not supported by that command.

    Also be sure your country variable has value labels attached to it. Without that, there is nothing you can do in the subsequent commands to get names instead of numbers.

    Comment


    • #3
      Dear Clyde Schechter thank you for your response,

      My country label does have labels. So in this case how can I proceed?

      Comment


      • #4
        Code:
        regress l_currwage i.country if female==0

        Comment


        • #5
          Dear Clyde Schechter thank you for your help,

          As a final question may I ask how to re-label the countries?

          Comment


          • #6
            The -label define- command has a -modify- option. So just write a -label define- command that enumerates the changes you want to make, and put -, modify- at the end.

            Comment


            • #7
              Dear Clyde Schechter,

              Thank you very much.

              Comment

              Working...
              X