Announcement

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

  • Binscatter and Confidence Interval

    Is any way you can add Confidence Interval in this code? So you can see it in the graph.

    binscatter cotiza_pension TT, line(connect) xline(0)

    Thanks!
    José

    Click image for larger version

Name:	Screen Shot 2023-10-27 at 12.16.22 PM.png
Views:	1
Size:	80.4 KB
ID:	1731779

  • #2
    From a glance at the help, the answer is no. binscatter (from SSC, as you are asked to explain: FAQ Advice #12) is I think intended only to be descriptive and exploratory, which to me is positive in aim Its attraction is perhaps greatest for some of its more unusual options, not so much its defaults as shown here.

    Your example doesn't convince as one where confidence intervals would be useful or interesting, however. I would reach here for a local polynomial as an exploratory smooth. My eye picks out a slight decline in outcome with the predictor how much of a big deal that is and how much variability there is around the changing level are different questions.

    Comment


    • #3
      Dear Jose Ignacio,

      There is a command, presented in last year's Stata Economics Virtual Symposium, that I believe does what you want. It is in line with Nick's intuition. The command's name is -binsreg-. You can find more information here:

      https://www.stata.com/symposiums/eco...2_Cattaneo.pdf

      Also, for anyone interested, this is the program of this year's virtual symposium.

      https://www.stata.com/symposiums/economics23/

      Comment

      Working...
      X