Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: RE: RE: Graph problems


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: RE: RE: Graph problems
Date   Fri, 31 Oct 2003 18:05:04 -0000

Dev Vencappa

> " Stata users, I don't have the graphics manual to refer to, and web
> resources are a bit limited (or I don't seem to get it
> right) for the
> question I have.
>  I am putting a second y-axis on a graph in Stata, but
> cannot get the
> scale to be different on each y axis in such a way as to make sure
> that each axis starts at the minimum value and finish at the maximum
> value of the label specified for each axis. That is to say, the
> starting point for axis 2 should be 0.33 but I also want
> the starting
> point of 1.6 for axis 1 to start at the same point at it starts for
> axis 2.  I am trying to get the minimum values for each variable to
> start at the very bottom on the x-axis  (eg axis 1 has a
> value of 1.6
> as the starting point, and axis 2 has the value 0.33 as the starting
> point. Using the command below simply gets 0.33 to start from the
> x-axis, but 1.6 to start somewhere higher on the y-axis for that
> variable.
>
> I have tried this command (one single line)
>
> line relempmanuf relwagemanuf year, yaxis(1 2)
> ytitle(relative wages,
> axis(1)) ytitle(relative employment, axis(2)) xlabel(1984(2)1997)
> ylabel(1.6(0.1)2, axis(1)) ylabel(0.33(0.01)0.39, axis(2)) sort
>

Try something like

twoway

( line relempmanuf year,
ytitle(relative wages) xlabel(1984(2)1997)
ylabel(1.6(0.1)2) sort )

( line relwagemanuf year, yaxis(2)
ytitle(relative employment, axis(2))
ylabel(0.33(0.01)0.39, axis(2)) sort)


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index