Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Comment on labels or legends in two-way line graphs


From   "R. Allan Reese" <[email protected]>
To   Stata distribution list <[email protected]>
Subject   st: Comment on labels or legends in two-way line graphs
Date   Fri, 16 May 2003 17:20:21 +0100 (BST)

> Alvaro Angeriz
> > I wonder if it is possible to attach labels to each line in
> > two-way line graphs.
On Fri, 16 May 2003, Nick Cox wrote:
> label in what sense? Do you mean text on the plot
> region? Something other than a legend?

I sent a solution to Alvaro and the list before Nick's comment arrived.
On a matter of style, I would when possible opt for a label by the line
instead of a separate legend (or key).  The examples in the Graphics
manual (p378-382) demonstrate the problems. One is the area occupied by
the legend that is denied to the plot.  A second is the additional work
caused to the reader in mapping the legend back to the plot. This is not a
trivial point; it is the equivalent of using simple direct language or
making the same statement in elaborate circumlocution. The problem is
further exacerbated when the visual cues are minimal and the mapping in
convoluted.

In all the Manual examples, the distinction between the lines relies
solely on tone. It is far more obvious in the graphs than in the legends.
You will often see graphs that use colored areas, and the tiny square of
color used for the key is difficult to match (because of well-known
perceptual problems) with a graph area.  When a color graph is
photocopied, of course the problems multiply!  One good tip is to add
redundancy - use a line style as well as a tone to distinguish.

The final point I'l make about legends, because all my students
unthinkingly do what the Graphics book shows, is that the legend should
follow the layout of the graph.  The example graph has two lines and the
line for females is apparently always on top; yet the legend puts males at
the top *because it followed the order of codes*! On p380, reverse the
categories and move the legend to the top of the box, and you almost have
a label at the end of each line.

R. Allan Reese                       Email: [email protected]

*
*   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/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index