25p. Statistics and histograms _printable_

25p. Statistics and histograms _printable_ - Statistics and...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
1 ©2009 by L. Lagerstrom Statistics and Histograms • Frequency distributions • Absolute vs. relative frequencies • Insights into data • The hist function • Creating relative frequency distributions • More options: the bar function, bin edges • Mean, median, standard deviation, and variance ©2009 by L. Lagerstrom Frequency Distributions Often in science and engineering we have sets of data from experiments or observations and need to figure out the key characteristics of the data. To do so, we of course calculate quantities such as the mean, the median, and the standard deviation. More generally, we construct a "frequency distribution." A frequency distribution divides the range of the data into intervals (or "bins") of a certain size, and then counts how many data points are in each interval. A classic example is a set of exam scores. To get an idea of the exam results, we might count how many scores there were in the 50s, the 60s, the 70s, the 80s, and the 90s (assuming the lowest score was in the 50s and the highest in the 90s). In other words, we are counting the frequency of a result in the 50s, 60s, 70s, etc. We often take the counts and plot them in a bar plot, giving a plot of the distribution of frequencies . This type of frequency distribution plot is called a histogram. ©2009 by L. Lagerstrom A Temperature Example Imagine that we have collected data on noon-time temperatures over a 10-day period for a certain city. The results are shown below : T = 74, 78, 83, 79, 72, 67, 69, 85, 91, 86 We want to plot a frequency distribution, so we decide to count how many temperatures were in the 60s, the 70s, the 80s, and the 90s. In other words, we have an interval or bin size of 10. (We could choose something else; for example, we might divide the range into intervals of 70-74, 75-79, 80-84, etc.) The histogram then looks as shown on the right, with four bins. ©2009 by L. Lagerstrom Absolute vs. Relative Frequencies The frequency distribution of temperature data on the previous slide is known as an "absolute frequency distribution," because we are counting the absolute number of temperatures that fall within each interval. We can also create a "relative frequency distribution." In this case, we calculate the fraction of temperatures that fall within each interval. To do so, we count the absolute number in each interval and then simply take the results and divide each interval's number by the total number of data points. So, for example, on the previous slide there are three temperatures that fall within the 80s interval in the absolute frequency distribution of the temperatures. Since there are 10 temperature data points total, the relative frequency for the 80s interval is its absolute frequency divided by 10, i.e., 3/10 = 0.3. This tells us that 30% of the measured temperatures fall within the 80s interval (or bin).
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2 ©2009 by L. Lagerstrom Absolute vs. Relative Frequencies, cont. Below we show an absolute frequency distribution and a relative
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/23/2010 for the course ENG 42325 taught by Professor Lagerstrom during the Spring '10 term at UC Davis.

Page1 / 6

25p. Statistics and histograms _printable_ - Statistics and...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online