Introduction to Statistics (MAT/SST 115.03 2008S)

R Notes for Topic 12: Normal Distributions


R notes for Activity 12-3: Blood Pressure and Pulse Rate Measurements

Read the data set with

BP = read.csv("/home/rebelsky/Stats115/Data/BloodPressures.csv")

You can find the column headings and a few lines of data with

head(BP)

You might want to reconstruct one or more of the dotplots to confirm that the data are the same (or at least similar enough).

library(BHH2)
dotPlot(BP$Systolic_BP)

For activity 12-3 c, you need to create a normal probability plot. The standard command for creating such a plot in R is qqnorm. Since one uses normal probability plots to explore relationship with the theoretical normal distribution, it can be helpful to see the straight line that would happen in that theoretical distribution. You add that line with qqline.

Here's the simplest way to create a normal probability plot for the systolic blood pressure data. The datax=T is necessary, but not worth explaining.

qqnorm(BP$Systolic_BP, datax=T, ylab="Systolic Blood Pressure")
qqline(BP$Systolic_BP, datax=T)

You can use similar commands to plot diastolic blood pressure and pulse rates.

Creative Commons License

Samuel A. Rebelsky, rebelsky@grinnell.edu

Copyright (c) 2007-8 Samuel A. Rebelsky.

This work is licensed under a Creative Commons Attribution-NonCommercial 2.5 License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc/2.5/ or send a letter to Creative Commons, 543 Howard Street, 5th Floor, San Francisco, California, 94105, USA.