@@ -270,7 +270,7 @@ We first group the data by the `replicate` variable—to group the
270
270
set of listings in each sample together&mdash ; and then use ` summarize `
271
271
to compute the proportion in each sample.
272
272
We print both the first and last few entries of the resulting data frame
273
- below to show that we end up with 20,000 point estimates, one for each of the 20,000 samples.
273
+ below to show that we end up with 20,000 point estimates, one for each of the 20,000 samples.\index{group \_ by}\index{summarize}
274
274
275
275
``` {r 11-example-proportions6, echo = TRUE, message = FALSE, warning = FALSE}
276
276
sample_estimates <- samples |>
@@ -381,7 +381,7 @@ one_sample <- airbnb |>
381
381
382
382
We can create a histogram to visualize the distribution of observations in the
383
383
sample (Figure \@ ref(fig:11-example-means-sample-hist)), and calculate the mean
384
- of our sample.
384
+ of our sample.\index{ggplot!geom \_ histogram}
385
385
386
386
``` {r 11-example-means-sample-hist, echo = TRUE, message = FALSE, warning = FALSE, fig.pos = "H", out.extra="", fig.cap = "Distribution of price per night (dollars) for sample of 40 Airbnb listings.", fig.height = 3.5, fig.width = 4.5}
387
387
sample_distribution <- ggplot(one_sample, aes(price)) +
@@ -1116,6 +1116,7 @@ To calculate a 95\% percentile bootstrap confidence interval, we will do the fol
1116
1116
1117
1117
To do this in R, we can use the ` quantile() ` function. Quantiles are expressed in proportions rather than
1118
1118
percentages, so the 2.5th and 97.5th percentiles would be the 0.025 and 0.975 quantiles, respectively.
1119
+ \index{percentile}
1119
1120
\index{quantile}
1120
1121
\index{pull}
1121
1122
\index{select}
0 commit comments