Announcement

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

  • #16
    Caspar, in #14, you say
    I'm using the German SOEP (Socio-Economic Panel) and i thought that i wouldn't have to use the svy-design because i'm only using one year(not several).
    Using the SOEP for one single year doesn't get you away from accounting for survey design. However, it might mean that you use cross-sectional weights of some kind rather than longitudinal weights

    Comment


    • #17
      Clyde:
      This is a very good suggestions. I didn't know that by invoking a do-file in another do-file the local of the upper one also work for the "lower" one.

      Stephen & Dick:
      Alright, thank you for preventing me from a huge mistake. I will include weights then.

      Comment


      • #18
        This is a very good suggestions. I didn't know that by invoking a do-file in another do-file the local of the upper one also work for the "lower" one.
        Be careful, that's not exactly right.

        Code:
        // CONTENT OF lower.do
        local demographics age i.sex i.ethnicity i.race i.income_group
        local anthropometrics height weight head_circ skinfold_thickness
        // etc....
        
        // CONTENT of upper1.do
        run lower // OR do lower
        
        // CONTENT of upper2.do
        include lower
        With upper1.do, the local macros defined in lower.do will not be in scope. lower.do will run, and while it is running, they are in scope, but they go out of scope as soon as control returns to upper1.do.

        With upper2.do, the content of lower.do is treated as if it were physically inserted into upper2.do, so that the local macros defined in lower.do are in scope from the -include- command to the end of upper2.do.

        So -include- will do this; but other ways of invoking a lower do-file will not.

        Comment


        • #19
          Thank you again! I didn't know about "run" and always use "include" but now i'm aware of the difference (and the command).

          Comment

          Working...
          X