Thank you Scott! Works perfectly!
Michael
At 07:57 AM 10/19/2006, you wrote:
> -----Original Message-----
> From: [email protected] [mailto:owner-
> [email protected]] On Behalf Of Michael McCulloch
> Sent: Thursday, October 19, 2006 9:21 AM
> To: [email protected]
> Subject: st: ytitle suboption -valuelabel-: how to label using the text
> from a variable
>
> Roger, I'm sorry I wasn't clear in my question.
> Now I realize that what I would like to do is label each of the -rcap-
> whisker bars from the graph below with the text contained in a variable
> <idstr>.
<snip>
Do you mean something like this?
clear
input str6 method es lci uci
Cox .89 .86 .99
MSM 1.2 .95 1.5
Pscore .31 .22 .51
end
l
gen pos = 6
replace pos = 12 if meth == "Cox"
encode method, gen(meth)
twoway rcap lci uci meth, horizontal msize(huge) ///
xtitle(Hazard Ratio and 95% Confidence Interval, margin(0 0 0 5)) ///
ytitle(Analysis Method) ylabel(none) ///
|| scatter meth es, msize(medlarge) legend(off) ///
|| scatter meth es, mlabel(meth) mlabsize(large) ///
mlabvpos(pos) mlabgap(2) msymbol(none)
Scott
*
* 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/
Best wishes,
Michael
____________________________________
Michael McCulloch
Pine Street Clinic
124 Pine Street, San Anselmo, CA 94960-2674
tel 415.407.1357
fax 415.485.1065
email: [email protected]
web: www.pinest.org
www.pinestreetfoundation.org
*
* 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/