Announcement

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

  • Stata Graph - Some Dashed Lines, Some Solid Lines

    Hi!

    I'm working on Stata 13/MP from a Mac.

    I am trying to get a graph showing the dynamics of variables var1-var8 over time.
    var1-var4 belong to the treatment group, while var5-var8 belong to the control group.
    I would like to have solid lines for var1-var4 (treatment group) and dashed lines for var5-var8 (control group). Is that possible?

    I was thinking about doing something like:
    tw (scatter var1 var2 var3 var4 var5 var6 var7 var8 time) (line var1 var2 var3 var4 var5 var6 var7 var8 time) ///
    lpattern(???)

    Would that be an option? If yes, could anyone help me with the syntax?

    Thanks a lot in advance!

    Ana

  • #2
    Code:
    line var1 var2 var3 var4 var5 var6 var7 var8 time, lp(solid solid solid solid dash ..)
    No guarantee on whether it looks good!

    Among other possibilities, see http://www.statalist.org/forums/foru...ailable-on-ssc

    Comment


    • #3
      Thanks, Nick! That's exactly what I wanted

      Comment


      • #4
        May I ask you one more question?

        I get the following graph, where the lines are very close to each other for every variable at the bottom.
        Is there a way to change the scale so that we can distinguish the lines at the bottom better?

        Thanks in advance!

        Comment


        • #5
          You could try the yscale(log) option - provided y is always a positive number.

          Comment

          Working...
          X