Graphics Reference
In-Depth Information
twoway histogram ttl exp, frequency width(1)
The frequency option changes the
scaling of the
-axis to represent the
number of cases that fall within the
range of
y
-values represented by the
bar. If we specify a bar width of 1, the
sum of the heights of the bars equals
the number of nonmissing values for
ttl exp .
Uses nlsw.dta & scheme vg past
x
0
10
20
30
Tot. work exper.
Let's now consider options that control the width of the bars and other characteristics
of the bars, such as color. Then, we will show you how to display the graph as a horizontal
histogram and demonstrate options that allow you to treat varname as a discrete variable.
We will use the vg blue scheme for these graphs.
twoway histogram ttl exp, gap(20)
The gap() option specifies the gap
between each of the bars. The gap is
created by reducing the width of the
bars. By default, the gap is 0, meaning
that the bars touch exactly and the
bars are reduced by 0%. Here, we
reduce the size of the bars by 20%,
making a small gap between the bars.
Uses nlsw.dta & scheme vg blue
.1
.08
.06
.04
.02
0
0
10
20
30
Tot. work exper.
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