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]
Re: st: Value labels won't show on box plot axis
From
[email protected] (Vince Wiggins, StataCorp)
To
[email protected]
Subject
Re: st: Value labels won't show on box plot axis
Date
Fri, 02 Aug 2013 17:10:39 -0500
Lee Walsh <[email protected]> reports that -graph box- does not respect
the -valuelabel- suboption of option -ylabel()-.
> graph box response [...],
> [...]
> ylabel(1(1)7, valuelabel)
> [...]
Lee is right, -valuelabel- is ignored. It is also ignored on
-graph bar- and -graph dot-. This behavior has been in -graph- since
Stata 8, and I am surprised Lee is the first person to come across it.
I suspect it has remained hidden so long because, as Allan Reese
<[email protected]> notes, folks rarely use categorical responses
on these types of graph.
Regardless, we will make -valuelabel- work on these graphs. I do not
want to promise an immediate solution, because these graphs are not
actually plotting the original data, but a mix of original data and
derived statistics. That just makes the solution more subtle, and we
want to be careful that it has no unexpected consequences.
In the interim, hopefully Nick Cox's workaround <[email protected]>
will serve Lee. Nick's solution is every bit as general the
-valuelabel- suboption. I reproduce Nick's solution below my
signature.
-- Vince
[email protected]
forval i = 1/7 {
local call `call' `i' "`: label (response) `i''"
}
graph box ... , ... ylabel(`call')
Where -7- is the number of categories and -response- is the y variable
<end>
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/