Chapter 4 Foundations for Inference Practice: 4.3, 4.13, 4.23, 4.25, 4.39, 4.47 Graded: 4.4, 4.14, 4.24, 4.26, 4.34, 4.40, 4.48
4.4 Heights of adults. Researchers studying anthropometry collected body girth measurements and skeletal diameter measurements, as well as age, weight, height and gender, for 507 physically active individuals. The histogram below shows the sample distribution of heights in centimeters. (a) What is the point estimate for the average height of active individuals? What about the median? (See the next page for parts (b)-(e).) Average Height : 171.1, Median : 170.3 (b) What is the point estimate for the standard deviation of the heights of active individuals? What about the IQR? SD : 9.4, IQR is Q3=Q1 : 177.8 - 163.8 = 14 (c) Is a person who is 1m 80cm (180 cm) tall considered unusually tall? And is a person who is 1m 55cm (155cm) considered unusually short? Explain your reasoning. Something usual is within one Standard Deviation. If the SD is 9.4, then 1.80 is usually tall, and 155 is unusually short because 180 falls within 1SD, but 155 does not.
upperoneSD <- 171.1 + 9.4
loweroneSD <- 171.1 - 9.4
cat(upperoneSD, loweroneSD)
## 180.5 161.7
SE(9.4,507)
## [1] 0.4174687
*This example and all its answers were cited from Page 412, as I modified the answers for 4.13 and modified the paramaters 4.14 Thanksgiving spending, Part I. The 2009 holiday retail season, which kicked off on November 27, 2009 (the day after Thanksgiving), had been marked by somewhat lower self-reported consumer spending than was seen during the comparable period in 2008. To get an estimate of consumer spending, 436 randomly sampled American adults were surveyed. Daily consumer spending for the six-day period after Thanksgiving, spanning the Black Friday weekend and Cyber Monday, averaged $84.71. A 95% confidence interval based on this sample is ($80.31, $89.11). Determine whether the following statements are true or false, and explain your reasoning. (a) We are 95% confident that the average spending of these 436 American adults is between $80.31 and $89.11. ‘False. Inference is made on the population parameter, not the point estimate. The point estimate is always in the confidence interval.’ (b) This confidence interval is not valid since the distribution of spending in the sample is right skewed. False. Provided the data distribution is not very strongly skewed (n = 436 in this sample, so we can be slightly lenient with the skew), the sample mean will be nearly normal, allow- ing for the method normal approximation described. (c) 95% of random samples have a sample mean between $80.31 and $89.11. ‘False. All samples have the possiblity of having different ranges, unless there exists a range which encompasses all samples.’ (d) We are 95% confident that the average spending of all American adults is between $80.31 and $89.11. ‘False. The confidence interval is not about a sample mean. Secondly using the quantifier All results in a logical fallacy unless proof of all exists.’ (e) A 90% confidence interval would be narrower than the 95% confidence interval since we don’t need to be as sure about our estimate. True. To be more confident that we capture the parameter, we need a wider interval. Think about needing a bigger net to be more sure of catching a fish in a murky lake. (f) In order to decrease the margin of error of a 95% confidence interval to a third of what it is now, we would need to use a sample 3 times larger. False. In the calculation of the standard error, we divide the standard deviation by the square root of the sample size. To multiply the SE (or margin of error) by 3, we would need to sample 22 = 4 times the number of people in the initial sample. (g) The margin of error is 4.4. ‘True. Optional ex- planation: This is true since the normal model was used to model the sample mean. The margin of error is half the width of the interval, and the sample mean is the midpoint of the interval.’
4.24 Gifted children, Part I. Researchers investigating characteristics of gifted children col- lected data from schools in a large city on a random sample of thirty-six children who were identified as gifted children soon after they reached the age of four. The following histogram shows the distribution of the ages (in months) at which these children first counted to 10 successfully. Also provided are some sample statistics. (a) Are conditions for inference satisfied? The conditions are met, there is a normal shape and slight varaince - let’s try it out. (b) Suppose you read online that children first count to 10 successfully when they are 32 months old, on average. Perform a hypothesis test to evaluate if this data provides convincing evidence that the average age at which gifted children fist count to 10 successfully is less than the general average of 32 months. Use a significance level of 0.10. H: Average Count is 32 Months H1: Average Count is less than 32 Months (c) Interpret the p-value in context of the hypothesis test and the data.
se <- SE(4.31, 36)
z <- (30.69 - 32)/(se)
cat("Do we accept the P Value? (p < .10): ")
## Do we accept the P Value? (p < .10):
if (pnorm(z) < .10){FALSE}
## [1] FALSE
cat("The P Value is: ", pnorm(z))
## The P Value is: 0.0341013
zVal <- qnorm(.90)
ciLower <- 30.69 - (zVal * se)
ciUpper <- 30.69 + (zVal * se)
cat("lower: ", ciLower, "upper: ", ciUpper )
## lower: 29.76942 upper: 31.61058
seGiftedChild <- SE(4.31, 36)
cat("(c) p value: ", seGiftedChild)
## (c) p value: 0.7183333
#x̄ ± z * SEx ̄
z <- (30.69 - 32) / 4.31
ciLower <- 36 + seGiftedChild*z
ciUpper <- 36 - seGiftedChild*z
cat("lower: ", ciLower, "upper: ", ciUpper )
## lower: 35.78167 upper: 36.21833
Gifted children, Part II. Exercise 4.24 describes a study on gifted children. In this study, along with variables on the children, the researchers also collected data on the mother’s and father’s IQ of the 36 randomly sampled gifted children. The histogram below shows the distribution of mother’s IQ. Also provided are some sample statistics.
(a)Perform a hypothesis test to evaluate if the data provided shows convincing evidencethat the average IQ of mothers of gifted children is different than the average IQ for the population at large, which is 100. Use a significance level of 0.10. (b) Calculate a 90% confidence interval for the average IQ of mothers of gifted children. (c) Do your results from the hypothesis test and the confidence interval agree? Explain.
4.34 CLT. Define the term “sampling distribution” of the mean, and describe how the shape, center, and spread of the sampling distribution of the mean change as sample size increases. Sampling Distribution of the mean: p.194: ‘The normal model for the sample mean tends to be very good when the sample consists of at least 30 independent observations and the population data are not strongly skewed. The Central Limit Theorem provides the theory that allows us to make this assumption.’ p.196: ‘As the sample size increases, the normal model for x ̄ becomes more reasonable. We can also relax our condition on skew when the sample size is very large.’
*Parts B, E are cited from page 414 4.40 CFLBs. A manufacturer of compact fluorescent light bulbs advertises that the distribution of the lifespans of these light bulbs is nearly normal with a mean of 9,000 hours and a standard deviation of 1,000 hours. (a) What is the probability that a randomly chosen light bulb lasts more than 10,500 hours?
lightbulbHours <- pnorm(10500, mean = 9000, sd = 1000, lower.tail = FALSE)
cat("Chance the the lifespan of 15 Lightbulbs lasts 10,500 Hours: ", lightbulbHours)
## Chance the the lifespan of 15 Lightbulbs lasts 10,500 Hours: 0.0668072
Describe the distribution of the mean lifespan of 15 light bulbs. ‘The population SD is known and the data are nearly normal, so the sample mean will be nearly normal with distribution N (μ, δ/sqrt(n))’ i.e. N(9000,0.0095)
What is the probability that the mean lifespan of 15 randomly chosen light bulbs is more than 10,500 hours?
lightbulbMeanHours <- pnorm(((10500-9000)/lightbulbHours), mean = 9000, sd = 1000, lower.tail = FALSE)
cat("Chance the mean lifespan of 15 Lightbulbs lasts 10,500 Hours: ", lightbulbMeanHours, "≈ 0" )
## Chance the mean lifespan of 15 Lightbulbs lasts 10,500 Hours: 1.484778e-41 ≈ 0
normalSample <- seq(9000 - (4 * 1000), 9000 + (4 * 1000))
randomSample <- seq(9000 - (4 * 1000), 9000 + (4 * SE(1000, 15)), length = 15)
secondNorm <- dnorm(normalSample,9000,1000)
secondRandom <- dnorm(randomSample,9000,1000)
plot(normalSample, secondNorm, col="black", lines(randomSample, secondRandom, col="red"))
(e) Could you estimate the probabilities from parts (a) and (c) if the lifespans of light bulbs had a skewed distribution? We could not estimate (a) without a nearly normal population distribution. We also could not estimate (c) since the sample size is not sufficient to yield a nearly normal sampling distribution if the population distribution is not nearly normal.
4.48 Same observation, different sample size. Suppose you conduct a hypothesis test based on a sample where the sample size is n = 50, and arrive at a p-value of 0.08. You then refer back to your notes and discover that you made a careless mistake, the sample size should have been n = 500. Will your p-value increase, decrease, or stay the same? Explain. The p-value will decrease. As a sample set becomes larger, the p-value will decrease in size.