Statalist


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

Re: st: row and column titles for graphs with the by option


From   Maarten buis <[email protected]>
To   [email protected]
Subject   Re: st: row and column titles for graphs with the by option
Date   Thu, 22 Oct 2009 03:33:54 -0700 (PDT)

Thanks to Scott and Martin for responding. Martin's solution to
look at graph editor pointed me in the right direction. Looking
at the recorded changes reminded me that one can manipulate 
graphs directly and gave me the right hints on how to do so.
Below is the graph I was after:

*------------------- begin example --------------------
sysuse auto, clear
recode rep78 1/2=3
egen byvar = group(foreign rep78)
label define byvar 1 "Average" 2 "Good" 3 "Excelent" ///
                   4 " " 5 " " 6 " "
label value byvar byvar
scatter price mpg ,                                  ///
    by(byvar,                                        ///
    r2title(Car type, orientation(rvertical))        ///
    t1title(Repair Record 1978, size(medsmall)))     ///
    name(col, replace) 

.col.plotregion1.r1title[3]._set_orientation rvertical
.col.plotregion1.r1title[3].text = {}
.col.plotregion1.r1title[3].text.Arrpush Domestic

.col.plotregion1.r1title[6].text = {}
.col.plotregion1.r1title[6].text.Arrpush Foreign

graph display
*---------------- end example ---------------------------

-- Maarten

--------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany

http://www.maartenbuis.nl
--------------------------




      

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