Graphics Reference
In-Depth Information
twoway scatter ownhome borninstate, msymbol(+) msize(small)
Previously, we saw that the size of the
symbols created using O , D , S ,and T
could be modified using an uppercase
or lowercase letter. Here, we use the
msize() (marker size) option to control
the size of the marker symbol, making
the marker symbol small. Other values
we could have chosen include vtiny ,
tiny , vsmall , small , medsmall ,
medium , medlarge , large , vlarge ,
huge , vhuge ,and ehuge .
Uses allstates.dta & scheme vg s1m
20
40
60
80
% born in state of residence
twoway scatter ownhome borninstate, msymbol(Oh) msize(*2)
We can specify the sizes as multiples of
the original size of the marker. In this
example, we make the markers twice
their original size by specifying
msize(*2) . Specifying a value less than
one reduces the marker size; e.g.,
msize(*.5) , would make the marker
half its normal size. See
Styles : Markersize (340) for more details.
Uses allstates.dta & scheme vg s1m
20
40
60
80
% born in state of residence
twoway scatter ownhome borninstate [aweight=propval100] ,
msymbol(oh)
Stata even allows us to size the symbols
based on the values of another variable
in your data file. This allows us, in a
sense, to graph three variables at once.
Here, we look at the relationship
between borninstate and ownhome and
then size the markers based on
propval100 using
[aweight=propval100] , weighting the
markers by propval100 .
Uses allstates.dta & scheme vg s1m
20
40
60
80
% born in state of residence
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