Announcement

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

  • LIne graph...is something missing?

    Dear all,

    I would like to ask for your help, if it is possible.

    I am trying to contruct a diagram (line) with two variables.
    var1= net income/population and var2=(net income-taxes)/population

    So I am using the following routine:
    line var1 var2 year, legend(size(medsmall))

    I was thinking that the diagram would have the following format:

    Click image for larger version

Name:	Capture1.JPG
Views:	1
Size:	23.6 KB
ID:	1658480

    *source stata

    But my diagram is like this....
    Click image for larger version

Name:	Graph.jpg
Views:	1
Size:	33.6 KB
ID:	1658483

    Is something wrong?

    Thank you in advance
    Kleon
    Last edited by Kleon Marenas; 07 Apr 2022, 11:00.

  • #2
    Add the sort option and see if that fixes the problem.

    Comment


    • #3
      Dear Mr. Cox,

      thank you very much.

      Now my graph is like this:
      Click image for larger version

Name:	Graph1.jpg
Views:	1
Size:	44.9 KB
ID:	1658494

      Still I think that something is wrong...
      Last edited by Kleon Marenas; 07 Apr 2022, 11:04.

      Comment


      • #4
        Perhaps you have panel or longitudinal data....

        I can't say more without seeing a proper data example.

        Comment

        Working...
        X