Graphics Reference
In-Depth Information
5
Box plots
-variable
with a median line at the 50th percentile. Whiskers extend from the box to the upper and
lower adjacent values and are capped with an adjacent line . Values exceeding the upper and
lower adjacent values are called outside values and are displayed as markers. This chapter
starts by showing the use of the over() option to break box plots down by categorical
variables and then showing how you can specify multiple
A box plot displays box(es) bordered at the 25th and 75th percentiles of the
y
-variables to display plots for
multiple variables. Next, we see further options that can be used to customize the display
of over() option, followed by options that control the display of categorical axes. Next,
we discuss options for legends, followed by options that control the display of the
y
y
-axis.
Finally, we cover options that control the look of boxes and the by() option.
5.1
Specifying variables and groups, yvars and over
This section introduces the use of box plots, illustrating the use of the over() option
for showing box plots by one or more grouping variables. Next, we give examples showing
how you can graph multiple variables at once by specifying additional
y
-variables, followed
y
-variables and the behavior
of over() options. See the group options table in [ G ] graph box for more details. This
section begins with the vg s2c scheme.
by some general options for controlling the display of multiple
graph box wage, over(grade4)
This is a box plot of wages broken
down by education. The over(grade4)
option breaks down wages by education
level (in four categories). By default,
the separate levels of grade4 are
graphed using the same color, and the
levels are labeled on the
-axis. The
graph shows a large number of outside
values that are displayed as markers
beyond the whiskers. The following
example shows how we can suppress the
display of the outside values.
Uses nlsw.dta & scheme vg s2c
x
Not HS
HS Grad
Some Coll
Coll Grad
157
The electronic form of this topic is solely for direct use at UCLA and only by faculty, students, and staff of UCLA.
Search WWH ::




Custom Search