Section 2.1

2 number

3 add up to 1

5

  1. washing your hands. 61% chooses this method.

  2. drinking orange juice. 2% chooses this method.

  3. 25%

13

  1. frequence total=4776 relative frequence distribution: Never: 125/4776 =0.026 Rarely:324/4776 =0.068 Sometimes:552/4776 =0.115 Most of the time:1257/4776 =0.263 Always:2518/4776 =0.527
datt <- c(125, 324, 552, 1257, 2518)

rel.freqq <- datt/sum(datt)

categoriess <- c("Never", "Rarely", "Sometimes", "Most of time", "Always")


answerr <- data.frame(categoriess,rel.freqq)

answerr
##    categoriess  rel.freqq
## 1        Never 0.02617253
## 2       Rarely 0.06783920
## 3    Sometimes 0.11557789
## 4 Most of time 0.26319095
## 5       Always 0.52721943
  1. 52.7%

  2. Never:2.6% Rarely: 6.8%

barplot(datt,main="Seat Belt Usage",names=categoriess, col =c("red","blue","green","yellow","orange"))

barplot(rel.freqq,main="Seat Belt Usage",names=categoriess, col =c("red","blue","green","yellow","orange"))

pie(datt,main="Seat Belt Usage",labels=categoriess, col =c("red","blue","green","yellow","orange"))

  1. descriptive statement

15

  1. frequence total: 1025 relative frequencey distribution: More than 1 hour a day: 377/1025= 0.368 Up to 1 hour a day: 192/ 1025= 0.187 A few times a week: 132/1025= 0.129 A few times a month or less: 81/1025= 0.079 Never: 243/1025= 0.237
dat <- c(377,192,132,81,243)

rel.freq <- dat/sum(dat)

categories <- c("More 1", "Up to 1", "Few a week", "Few a month", "Never")


answer <- data.frame(categories,rel.freq)

answer
##    categories   rel.freq
## 1      More 1 0.36780488
## 2     Up to 1 0.18731707
## 3  Few a week 0.12878049
## 4 Few a month 0.07902439
## 5       Never 0.23707317
  1. 23.7% never use the internet

barplot(dat,main="Internet Usage",names=categories, col =c("red","blue","green","yellow","orange"))

barplot(rel.freq,main="Internet Usage(Relative Freq)",names=categories, col =c("red","blue","green","yellow","orange"))

pie(dat,main="Internet Usage",labels=categories, col =c("red","blue","green","yellow","orange"))

Section 2.2

7 true

8 false

9

  1. 8

  2. 2

  3. 15 times

  4. 5: 11 times 4: 7 times so there were 4 more times of 5s than 4s

  5. 13%

  6. bell shaped

10

  1. 4

  2. 9 weeks

  3. 17%

  4. bell shaped but also kind of skewed to the left

13

  1. skewed right. lowest to highest income

  2. bell shapes because there is probably a higher frequence of people getting a mediun score rather than super low or high

  3. uniform

  4. skewed right because usualy the older a person is, they are likely to have Alzheimers

14

  1. bell shape because there could be less drinks during some weeks, and more during other weeks

  2. unifrom because there should of a relaitvly equall number of students in all age groups

  3. skewed right because usually older people need hearing aids

  4. bell shaped because there are short men and tall men and usually theres more men who are “average” height

15

dattt <- c(16, 18, 12, 3, 1)

rel.freqqq <- dattt/sum(dattt)

categoriesss <- c("Zero", "One", "Two", "Three", "Four")

answerrr <- data.frame(categoriesss,rel.freqqq)

answerrr
##   categoriesss rel.freqqq
## 1         Zero       0.32
## 2          One       0.36
## 3          Two       0.24
## 4        Three       0.06
## 5         Four       0.02
  1. 24%

  2. 60%

16

free_throws <- c(16, 11, 9, 7, 2,3,0,1,0,1)

rel.freqqq <- free_throws/sum(free_throws)

categoriesss <- c("1", "2", "3", "4","5","6","7","8","9","10")

answerrr <- data.frame(categoriesss,rel.freqqq)

answerrr
##    categoriesss rel.freqqq
## 1             1       0.32
## 2             2       0.22
## 3             3       0.18
## 4             4       0.14
## 5             5       0.04
## 6             6       0.06
## 7             7       0.00
## 8             8       0.02
## 9             9       0.00
## 10           10       0.02
  1. 14%

  2. 2%

  3. 90%

25

  1. discrete because the data set has finite values, not infinit

tv <- c(1, 1, 1, 2, 1,
        1, 2, 2, 3, 2,
        4, 2, 2, 2, 2,
        2, 4, 1, 2, 2,
        3, 1, 3, 1, 2,
        3, 1, 1, 2, 1,
        5, 0 ,1, 3, 3,
        1, 3, 3, 2, 1)

#table(tv)

tv <- c(1,14,14,8,2,1)

tv.freq <- tv/sum(tv)

tv.cat <- c("0", "1", "2", "3","4","5")

freq.tab <- data.frame(tv.cat,tv)
rfreq.tab <- data.frame(tv.cat,tv.freq)


freq.tab
##   tv.cat tv
## 1      0  1
## 2      1 14
## 3      2 14
## 4      3  8
## 5      4  2
## 6      5  1
rfreq.tab
##   tv.cat tv.freq
## 1      0   0.025
## 2      1   0.350
## 3      2   0.350
## 4      3   0.200
## 5      4   0.050
## 6      5   0.025
  1. 20%

  2. 7.5%