Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Re: Marginsplot and labelled reference line


From   Martyn Sherriff <[email protected]>
To   [email protected]
Subject   st: Re: Marginsplot and labelled reference line
Date   Thu, 15 Mar 2012 12:13:02 +0000

I am using the following code add two reference lines to marginsplot (Stata 12):

marginsplot, title("Black background")										///
	plot1opts(lcolor(gs9) mcolor(gs9)) ci1opts(lcolor(gs9))						///
	plot2opts(lcolor(gold) mcolor(gold)) ci2opts(lcolor(gold))						///
	plot3opts(lcolor(red) mcolor(red)) ci3opts(lcolor(red))						///
	plot4opts(lcolor(maroon) mcolor(maroon)) ci4opts(lcolor(maroon))			       ///
	plot5opts(lcolor(dkgreen) mcolor(dkgreen))
ci5opts(lcolor(dkgreen))			       ///
	plot6opts(lcolor(midgreen) mcolor(midgreen)) ci6opts(lcolor(midgreen))			///
	plot7opts(lcolor(dkorange) mcolor(dkorange)) ci7opts(lcolor(dkorange))			///
	yline(1 2, lpattern(shortdash) lcolor(black))

I want to label the right hand y axis with 50 % and 100 %
corresponding to the '1' and '2' reference lines but cannot find the
correct syntax. Or do I need to explicit add and label the lines with
addplot?

Thank you,
Martyn
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index