More on sampling distribution of prices
Do the same thing, but now create a vector called sample_means150
to store means of samples of size 150.
Describe the shape of this sampling distribution, and compare it to the sampling distribution for a sample size of 50. Based on this sampling distribution, what would you guess to be the mean sale price of homes in Ames?
This exercise is part of the course
Data Analysis and Statistical Inference
Exercise instructions
- Create
sample_means150
and populate it with the means of 5000 samples of size 150. - Finish with drawing histograms of both
sample_means50
andsample_means150
.
Hands-on interactive exercise
Have a go at this exercise by completing this sample code.
# The ames data frame and area and price objects are already loaded into the workspace
# sample_means50 is already loaded.
# Initialize sample_means150
sample_means150 <-
# Finish the for loop
for (i in 1:___) {
}
# Draw histograms of sample_means50 and sample_means150