Graphics Reference
In-Depth Information
twoway scatter propval100 rent700 ownhome, legend(cols(1))
The legend() option allows you to
control the contents and display of the
legend. Here, we use the
legend(cols(1)) option to indicate
that we want the legend to display as a
single column. See Options : Legend
(287) for more details about the
legend() option.
Uses allstates.dta & scheme vg outm
40
50
60
70
80
% who own home
% homes cost $100K+
% rents $700+/mo
twoway scatter propval100 ownhome, text(62 45 "DC")
In this graph, there is a single
observation that stands out from the
rest. Rather than use the mlabel()
option to label all of the markers, we
may want to label just the outlying
point. Here, we use the text() option
to add the text DC at the (
DC
)
coordinates of (62,45), in effect labeling
that point; see Options : Adding text
(299) for more details.
Uses allstates.dta & scheme vg outm
y
,
x
40
50
60
70
80
% who own home
twoway scatter propval100 ownhome,
title(This is a Title, box bfcolor(dimgray)
blcolor(black) blwidth(thick))
Most items of text on a Stata graph
actually display within a box. We
illustrate this with the title() option
showing how we can place a box around
this text. We make the background
color of the box light gray and the
outline thick and black. These options
are described in more detail in
Options : Textboxes (303).
Uses allstates.dta & scheme vg outm
This is a Title
40
50
60
70
80
% who own home
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