Dice rolls. (3.6, p. 92) If you roll a pair of fair dice, what is the probability of

  1. getting a sum of 1? The possible outcome for a pair of dice is 36. Solution: The probability of getting a sum of 1 from a pair of fair dice is 0.

  2. getting a sum of 5? Solution: The probability of getting a sum of 5 is 4/36. (1,4; 4,1; 3,2; and 2,3) = 1/9.

  3. getting a sum of 12? Solution: The probability of getting a sum of 12 is 1/36 from a pair of dice.


Poverty and language. (3.8, p. 93) The American Community Survey is an ongoing survey that provides data every year to give communities the current information they need to plan investments and services. The 2010 American Community Survey estimates that 14.6% of Americans live below the poverty line, 20.7% speak a language other than English (foreign language) at home, and 4.2% fall into both categories.

  1. Are living below the poverty line and speaking a foreign language at home disjoint?

Solution: No, since there are 4.2% of the population living below the poverty line and speaking a language other than English.

  1. Draw a Venn diagram summarizing the variables and their associated probabilities.
library(VennDiagram)
## Loading required package: grid
## Loading required package: futile.logger
library(ggplot2)
Below_poverty <- 14.6
Foreign_Language <- 20.7
Both <- 4.2
Poverty_only <- Below_poverty - Both
Foreign_Language_only <- Foreign_Language - Both

plot <- draw.pairwise.venn(Below_poverty, 
                                Foreign_Language,
                                cross.area=Both, 
                                c("Below_poverty", "Foreign_Language"), 
                                fill=c("green", "lightblue"),
                                cat.dist=-0.08,
                                ind=FALSE)
grid.draw(plot)

  1. What percent of Americans live below the poverty line and only speak English at home? Solution: 14.6% of Americans live below the poverty line, 20.7% speak a language other than English (foreign language) at home, and 4.2% fall into both categories. English Only = P(Below Poverty - Both)) = 14.6% - 4.2% = 10.4%

  2. What percent of Americans live below the poverty line or speak a foreign language at home? Solution: P(below poverty line or speak foreign language) - P(Both) = 14.6% + 20.7% - 4.2% = 31.1%

  3. What percent of Americans live above the poverty line and only speak English at home? Solution: P(Above proverty line and Speak English only) = (1 - 14.6%) * 79.3% = 67.7%

  4. Is the event that someone lives below the poverty line independent of the event that the person speaks a foreign language at home? Solution: No. The events are not independent.


Assortative mating. (3.18, p. 111) Assortative mating is a nonrandom mating pattern where individuals with similar genotypes and/or phenotypes mate with one another more frequently than what would be expected under a random mating pattern. Researchers studying this topic collected data on eye colors of 204 Scandinavian men and their female partners. The table below summarizes the results. For simplicity, we only include heterosexual relationships in this exercise.

  1. What is the probability that a randomly chosen male respondent or his partner has blue eyes? Solution Using Addition Rule: P(Male with Blue eyes) + P(Partner Female with Blue eyes) - P(Both Male Female with Blue eyes) P(MBlue) + P(FBLue) - P(MBlue AND FBlue)
MBlue <- 114/204
FBlue <- 108/204
FMBlue <- 78/204
Mblue_Only <- paste(round((MBlue + FBlue - FMBlue)*100, digits=1), "%", sep = "")
Mblue_Only
## [1] "70.6%"

There is about 71% that Male or Female has Blue eyes

  1. What is the probability that a randomly chosen male respondent with blue eyes has a partner with blue eyes? P(Female with Blue eyes| Male with Blue eyes)
FandMblue <- paste(round((FMBlue)*100, digits = 1), "%", sep = "")
FandMblue
## [1] "38.2%"

There is 38.2% chance that a blue eyed male respondent has partner with Blue eyes

  1. What is the probability that a randomly chosen male respondent with brown eyes has a partner with blue eyes? What about the probability of a randomly chosen male respondent with green eyes having a partner with blue eyes?
MBBR_eyes <- 54
MBR_FB_eyes <- 19
MBR_FB <- (MBR_FB_eyes/MBBR_eyes)

MGR_eyes <- 36
MGR_FB_eyes = 11
MGR_FB_eyes <- (MGR_FB_eyes/MGR_eyes)
  1. Does it appear that the eye colors of male respondents and their partners are independent? Explain your reasoning.

No, it appears that male eye color and their partner’s eye color are dependent.


Books on a bookshelf. (3.26, p. 114) The table below shows the distribution of books on a bookcase based on whether they are nonfiction or fiction and hardcover or paperback.

  1. Find the probability of drawing a hardcover book first then a paperback fiction book second when drawing without replacement. Solution P(Hardcover first) = 28/95 P(paperback fiction) = 59/94
Prob <- paste(round(((28/95) * (59/94))*100, digits = 2), "%", sep = "")
Prob
## [1] "18.5%"
  1. Determine the probability of drawing a fiction book first and then a hardcover book second, when drawing without replacement. Solution P(first hard cover fiction =(13/95) p(second hard cover) = (27/94) P(firstpapaerback fiction) = (59/95) P(second hard cover) = (28/94)
Prob <- paste(round(((13/95)*(27/94) + (59/95)*(28/94))*100, digits = 2), "%", sep = "")
Prob
## [1] "22.43%"
  1. Calculate the probability of the scenario in part (b), except this time complete the calculations under the scenario where the first book is placed back on the bookcase before randomly drawing the second book. Solution P(firstfiction =(72/95) p(second hardcover) = (28/95)
Prob <- paste(round(((72/95) * (28/95))*100, digits = 2), "%", sep = "")
Prob
## [1] "22.34%"
  1. The final answers to parts (b) and (c) are very similar. Explain why this is the case. Solution The observations are almost independent even when sampling with no replacement.

Baggage fees. (3.34, p. 124) An airline charges the following baggage fees: $25 for the first bag and $35 for the second. Suppose 54% of passengers have no checked luggage, 34% have one piece of checked luggage and 12% have two pieces. We suppose a negligible portion of people check more than two bags.

  1. Build a probability model, compute the average revenue per passenger, and compute the corresponding standard deviation.
bags <- c(0,1,2)
fees <- c(0,25,25+35)
prob <- c(.54, .34, .12)
revenue <- data.frame(bags, fees, prob)
Avgrevenue <- sum(fees * prob)
Avgrevenue
## [1] 15.7
variance <- ((fees - Avgrevenue)^2) * prob
var <- sum(variance)
stand_dev <- round(sqrt(var),2)
stand_dev
## [1] 19.95

The average revenue per customer is $15.70 and the standard deviation is 19.95

  1. About how much revenue should the airline expect for a flight of 120 passengers? With what standard deviation? Note any assumptions you make and if you think they are justified.
Expectedrev <- Avgrevenue * 120
Expectedrev
## [1] 1884
var_pass <- (120 * stand_dev^2)
var_pass
## [1] 47760.3
sd_pass <- round(sqrt(var_pass),2)
sd_pass
## [1] 218.54

The standard deviation for the expected revenue of 120 passengers is 218.54


Income and gender. (3.38, p. 128) The relative frequency table below displays the distribution of annual total personal income (in 2009 inflation-adjusted dollars) for a representative sample of 96,420,486 Americans. These data come from the American Community Survey for 2005-2009. This sample is comprised of 59% males and 41% females.

  1. Describe the distribution of total personal income.
income <- c("$1 to $9,999","$10,000 to $14,999","$15,000 to $24,999","$25,000 to $34,999","$35,000 to $49,999","$50,000 to $64,999","$65,000 to $74,999","$75,000 to $99,999","$100,000 or more")
total <- c(2.2,4.7,15.8,18.3,21.2,13.9,5.8,8.4,9.7)
dist <- data.frame(income, total)
dist
##               income total
## 1       $1 to $9,999   2.2
## 2 $10,000 to $14,999   4.7
## 3 $15,000 to $24,999  15.8
## 4 $25,000 to $34,999  18.3
## 5 $35,000 to $49,999  21.2
## 6 $50,000 to $64,999  13.9
## 7 $65,000 to $74,999   5.8
## 8 $75,000 to $99,999   8.4
## 9   $100,000 or more   9.7
barplot(dist$total, names.arg = income, xlab = "Annual Income", ylab = "Total")

  1. What is the probability that a randomly chosen US resident makes less than $50,000 per year?
prob <- sum(dist[1:5,]$total)
prob
## [1] 62.2

The probability of selected US resident makes less than $50K is 62%

  1. What is the probability that a randomly chosen US resident makes less than $50,000 per year and is female? Note any assumptions you make. Solution: There’re 41% female.
prob_female <- 0.41 * prob
prob_female
## [1] 25.502

About 26% makes less than $50K and are female.

  1. The same data source indicates that 71.8% of females make less than $50,000 per year. Use this value to determine whether or not the assumption you made in part (c) is valid.
Female <- 0.718 * 0.41
Female
## [1] 0.29438

Although the values are close, if this assumption is true, then men seems to belong to the higher income scale than women.