STA 402/502 Homework 2: Analyzing the Backache Data, Assignments of Statistics

Instructions and data for completing homework assignment in a statistics course. Students are required to read in the backache data from a given url, construct variables such as body mass index (bmi), create indicator variables, define labels, and generate descriptive statistics and visualizations. The goal is to analyze the relationship between back pain severity and various factors including weight, height, pregnancy history, and pain relievers.

Typology: Assignments

Pre 2010

Uploaded on 08/19/2009

koofers-user-v16
koofers-user-v16 🇺🇸

10 documents

1 / 11

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
STA 402/502 Homework 2
M:\baileraj\Classes\Fall 2007\sta402\hw\Homework-02-31aug07doc
Assigned: 05 Sep. 2007
Due: 12 Sep. 2007
1. Read the backache data from
http://lib.stat.cmu.edu/datasets/backache
into SAS. This data set is also given at the bottom of this page.
Note that the order of the variables in the data set is:
Patient's number
Back pain severity
(values: 0=NILL; 1="nothing worth troubling about";
2="troublesome but not severe"; 3="severe")
Month when pregnancy pain started
Age of patient (years)
Height (m)
Weight (kg) at start of pregnancy
Weight (kg) at end of pregnancy
Weight (kg) of baby
Number of previous pregnancies
Backache with previous pregnancy
(values: 1=not applicable; 2=NO; 3=YES; 4=SEVERE)
Factors relieving backache (8 separate variables with 0=NO; 1=YES)
1 tablets (e.g. aspirin)
2. hot water bottle
3. hot bath
4. Cushion behind back in chair
5. Standing
6. Sitting
7. Lying
8. Walking
Factors aggravating pain (15 separate variables with 0=NO; 1=YES)
1 Fatigue
2. Bending
3. Lifting
4. Making Beds
5. Washing up
6. Ironing
7. A bowel action
8. Intercourse
9. Coughing
10. Sneezing
11. Turning in bed
12. Standing
13. Sitting
14. Lying
15. Walking.
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download STA 402/502 Homework 2: Analyzing the Backache Data and more Assignments Statistics in PDF only on Docsity!

STA 402/502 Homework 2

M:\baileraj\Classes\Fall 2007\sta402\hw\Homework-02-31aug07doc Assigned: 05 Sep. 2007 Due: 12 Sep. 2007

  1. Read the backache data from http://lib.stat.cmu.edu/datasets/backache into SAS. This data set is also given at the bottom of this page. Note that the order of the variables in the data set is:

Patient's number Back pain severity (values: 0=NILL; 1="nothing worth troubling about"; 2="troublesome but not severe"; 3="severe") Month when pregnancy pain started Age of patient (years) Height (m) Weight (kg) at start of pregnancy Weight (kg) at end of pregnancy Weight (kg) of baby Number of previous pregnancies Backache with previous pregnancy (values: 1=not applicable; 2=NO; 3=YES; 4=SEVERE) Factors relieving backache (8 separate variables with 0=NO; 1=YES) 1 tablets (e.g. aspirin)

  1. hot water bottle
  2. hot bath
  3. Cushion behind back in chair
  4. Standing
  5. Sitting
  6. Lying
  7. Walking Factors aggravating pain (15 separate variables with 0=NO; 1=YES) 1 Fatigue
  8. Bending
  9. Lifting
  10. Making Beds
  11. Washing up
  12. Ironing
  13. A bowel action
  14. Intercourse
  15. Coughing
  16. Sneezing
  17. Turning in bed
  18. Standing
  19. Sitting
  20. Lying
  21. Walking.

Use sensible variable names. In addition, use relevant titles for the output.

  1. Construct the body mass index of each woman at the start of the pregnancy. BMI = WT/(HT^2) with WT (kg) and HT (m).
  2. Construct an indicator variable that takes on value=1 if this is the woman does not have a child from a previous pregnancy.
  3. Set up informative labels for all of the variables you input or construct.
  4. Define a new variable that will contain a formatted version of
  • Back pain severity
  • Backache with previous pregnancy
  • Factors relieving backache
  • Factors aggravating pain
  1. Generate a description of your data set using PROC CONTENTS. Include in your solution a listing of the variables, their assigned labels, etc. from this procedure.
  2. Generate a table with the five-number summary for all of the numeric variables. Recall that the “5 number summary” includes (min, Q1, M, Q3, max).
  3. Generate a histogram of BMI measurements. Comment on distribution center and shape.
  4. Produce a figure with a separate boxplot of BMI for each of the back pain severity levels (i.e. one figure with 4 boxplots). Comment on BMI differences between back pain severity levels.
  5. Construct a table of relative frequencies of the following categories of BMI based on http://www.halls.md/ideal- weight/medical.htm (accessed: 31 Aug. 07). For women, Underweight: BMI < 19. normal "ideal": BMI = 19.1-25.8; Marginally overweight: BMI=25.8-27. Overweight: BMI=27.3-32. Very overweight/obese: BMI>32.