y axis

y axis

by Laura Koth -
Number of replies: 1

Hi everyone,

from last weeks homework, 3, for these two different ex plots, what do the y axis represent?

Create a histogram of systolic blood pressure (bpsystol)
***/
histogram bpsystol

in this one, sbp is on x, but don't understand units of y

/***
Plot frequency instead of density
***/
histogram bpsystol, frequency

in this one, sbp on x, is the number of people with that bp on y?

Change the number of bins to 15
***/
histogram bpsystol, frequency normal bin(15)

for this one, why did the freq units double?

In reply to Laura Koth

Re: y axis

by Kristen -


histogram bpsystol

y-axis is density - default for histogram.  density scales the height of the bars so that the sum of their areas equals 1.


histogram bpsystol, frequency

y-axis is frequency. frequency scales the height of the bars so that each bar's height is equal to the number of observations in the category.  Thus the sum of the heights is equal to the total number of observations.


histogram bpsystol, frequency normal bin(15)

y-axis is still frequency. Now there are fewer rectangles(bins) so the height of each increases because there are now more people in each bin. The sum of the heights will still equal the total number of observations. 


---

Lots of great help in the help file for histograms (help histogram)