Announcement

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

  • lpoly weighting problem

    Hi Everyone,

    Sorry if this is too specific of a question. I've been having some problems with using pweights for an lpoly regression - Stata returns "pweight not allowed". I've scoured the documentation, and have seen examples of people using pweights in similar cases. I can't figure out what I'm doing wrong! I've tried this with two regressions, which look like the following: twoway (lpolyci yvar xvar [pweights=weight]), by(state)

    and

    twoway (lpolyci yvar xvar if region==1) (lpolyci yvar xvar if region==2)

    Where regions are collections of states.

    Thank you very much for your help!


  • #2
    http://www.stata.com/help.cgi?twoway_lpolyci explains that only fweights and aweights are supported. Whether there is a fundamental problem which would be the reason why it is not implemented or it's just that StataCorp have yet to implement it, I can't say.

    As the main purpose of this method is (arguably) just to indicate possible patterns I doubt you're missing much by using other weights instead. If your data are really spatial data any way, then any confidence intervals are not exact without some recognition of dependence structure, so that's another limitation.

    In practice also I would be much more concerned with varying the bandwidth and (secondarily) the kernel type rather than just taking the defaults. The defaults are not based on any kind of optimisation. It's my impression that the defaults typically and deliberately smooth not much with the intention of getting you to chose your own better settings. Otherwise put, getting confidence intervals on a smooth based on arbitrary defaults is taking the results more seriously than they deserve.
    Last edited by Nick Cox; 13 Jun 2015, 03:23.

    Comment


    • #3
      See a nearly identical question asked on the same day at:http://www.statalist.org/forums/foru...-other-weights
      Steve Samuels
      Statistical Consulting
      [email protected]

      Stata 14.2

      Comment

      Working...
      X