Announcement

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

  • Adding x-ticks to every graph within a 'by' set for a twoway line

    Hello, I have a general question about graphs containing a 'by' set. I am attempting to show how unionization rates have declined by education level over the years. I have attached an image of my two way line graph, I want every level of education to contain an x-axis with the relevant years. Is there a method to make this happen? I cannot find anything in the help section pertaining to this topic, any help is appreciated. Thanks!

    Relevant code:
    collapse (mean) Union , by(Schooling survyear)
    twoway line Union survyear, by(Schooling)


    Click image for larger version

Name:	Union.png
Views:	1
Size:	86.9 KB
ID:	1487890

  • #2
    Sounds like an extra option, say

    Code:
    xtic(1999/2017)
    except that your graph implies that there wasn't a survey every year.

    You may want to tune the label default to say

    Code:
    xla(2000(5)2015)
    In general, start at

    Code:
    help axis options

    Comment

    Working...
    X