Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

re: Re: st: placing two textboxes in a graph on the x-axis


From   "Ariel Linden, DrPH" <ariel.linden@gmail.com>
To   <statalist@hsphsun2.harvard.edu>
Subject   re: Re: st: placing two textboxes in a graph on the x-axis
Date   Sat, 27 Aug 2011 10:36:54 -0400

Maarten, you are fantastic! This is exactly what I needed! I didn't even
know about xmlabel.

Thanks for your help!

Ariel

Date: Fri, 26 Aug 2011 10:02:38 +0200
From: Maarten Buis <maartenlbuis@gmail.com>
Subject: Re: st: placing two textboxes in a graph on the x-axis

On Thu, Aug 25, 2011 at 11:34 PM, Ariel Linden, DrPH wrote:
> I would like to place 2 textboxes on the x-axis of a graph (one to the
right
> and one to left of the center point 0 where the xlabel would go) that says
> "benefits treatment" and "benefits controls" (as you'd see in a forest
> plot).

What about this?

*-------------- begin example ------------------
sysuse nlsw88, clear
replace grade = grade - 12

scatter ttl_exp grade , ///
        xmlab(-2.5 `""benefits" "treatment""' ///
               2.5 `""benefits" "controls""', ///
               noticks labsize(medium) )
*---------------- end example --------------------
(For more on examples I sent to the Statalist see:
http://www.maartenbuis.nl/example_faq )

Hope this helps,
Maarten

*
*   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   |   Site index