Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 72772

How to adapt the y-axis in a two-way graph?

$
0
0
Dear Stata Users,

I am facing some difficulties when changing the range of values that should be displayed on the y-axis in my two-way plot. I want the y-axis to range from -0.2 to 0.2 but more zoomed in so that -0.2 is at the intersection of y and x axis where one would usually have the zero. In the example graph the 0.2 starts half in the graph and I want the range to be more zoomed in.

Do you have any idea on how I can modify my code?

Code:
twoway (scatter residual time, msy(x)) (line av_residual time, yline(0)) yscale(r(-0.2 0.2)) yla(-0.2(0.2)0.2))

Viewing all articles
Browse latest Browse all 72772

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>