Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Trouble labeling x-axis and a question about Graphics Editor


From   "Scott Merryman" <scott.merryman@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Trouble labeling x-axis and a question about Graphics Editor
Date   Mon, 29 Sep 2008 09:59:37 -0500

On Mon, Sep 29, 2008 at 9:35 AM, Polis, Chelsea B. <cpolis@jhsph.edu> wrote:
> I am having trouble labeling the x-axis of my graph, and can't figure out why.  It would be greatly appreciated it someone could help me figure out why I am getting the following error message:
>
> My command is as follows:
> . graph bar pctnonhc pctinj pctpill pctnorp, over(round) stack title("Use of any contraception in HIV+ women, by round") legend(cols(4) label(1 "Non-hormonal") label(2 "Injectables") label(3 "Pills") label(4 "Norplant")) ytitle("Percent using method") xtitle("Round")
>
> xtitle(Round") not allowed, " invalid name
> r(198);
>

You could use the -b1title()- or -b2title()- option to label the
categorical axis (see Michael Mitchell's "A Visual Guide to Stata
Graphics" page 193).

Scott
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index