I have a twoway graph overlaying two scatterplots and one fitted line. I want to suppress the legend for the fitted line but keep it for the two scatterplots.
My code looks like this:
Code:
sysuse auto, clear separate price, by(foreign) tw (scatter price1 mpg) (scatter price0 mpg) (lfit price mpg)
The most natural approach to me was to use legend(off) within the lfit parentheses like below, but it deletes the whole legend.
Code:
tw (scatter price1 mpg) (scatter price0 mpg) (lfit price mpg, legend(off))
Antonin
0 Response to Suppress legend in twoway graph for some scatter
Post a Comment