DSCI 100 TEST EVALUATION ANSWERS AND
QUESTIONS SET A+
✔✔What does a sampling distribution help us understand? - ✔✔It helps us see how
much we would expect our sample proportions from a population to vary for samples of
a set size.
✔✔What is bootstrapping in statistics? - ✔✔Taking more samples of the same size from
our sample.
✔✔What is the purpose of bootstrapping? - ✔✔To create an approximation of the
sampling distribution called the bootstrap distribution.
✔✔Does bootstrapping result in a true sampling distribution? - ✔✔No, it results in an
approximation called the bootstrap distribution.
✔✔7 steps to bootstrap - ✔✔1. randomly select an observation from the original
sample, which was drawn from the population
2. record observation value
3. replace that observation
4. repeat steps 1-3 until there are n observations, which forms a bootstrap
5. calculate bootstrap point estimate of the observations in the bootstrap sample
6. repeat 1-5 many times to create bootstrap distribution
7. calculate plausible range of values around our observed point estimate
✔✔What is a confidence interval? - ✔✔A range of plausible values for the population
parameter.
✔✔What percentage of observations are below the lower bound in a 95% confidence
interval? - ✔✔2.5%
✔✔What percentage of observations are below the upper bound in a 95% confidence
interval? - ✔✔97.5%
, ✔✔What is the first step in calculating a confidence interval? - ✔✔Arrange observations
in ascending order.
✔✔difference between rmse and rmspe - ✔✔rmse is for training set, rmspe is for testing
set
✔✔code lines for calculating rmse/rmspe - ✔✔fit |>
predict |>
bind_cols |>
metrics |>
filter |>
select |>
pull
✔✔how to make a data analysis reproducible - ✔✔- setting a random seed
- documenting each step during the analysis
✔✔markdown cell - ✔✔- for typing common text, like explanations
- help to organize and explain analysis
✔✔code cell - ✔✔- write and run code for R to use
- performing calculations, forming plots, etc
✔✔what does tbl(conn, "projects") do if conn is a connection to a database - ✔✔- Gets
the data table called "projects" from the database connection "conn"
- Useful because it creates a data frame in R that you can read and work with in R
✔✔why is pipe operator preferred - ✔✔- enhanced clarity when reading and writing the
code
- separates each function in order so steps are clear
✔✔what does facet_grid do - ✔✔splits a plot into multiple plots based on the values of
1-2 variables
✔✔when to use facet_grid - ✔✔to see how a relationship changes across different
categories
✔✔advantage of knn regression compared to linear reg - ✔✔- good fit for all sorts of
data, including nonlinear
- way easier to implement
✔✔disadvantage of knn reg compared to linear reg - ✔✔- slow when there is a lot of
data
- cannot make predictions outside of data range
- cannot interpret based off knn reg since it does not return an equation
QUESTIONS SET A+
✔✔What does a sampling distribution help us understand? - ✔✔It helps us see how
much we would expect our sample proportions from a population to vary for samples of
a set size.
✔✔What is bootstrapping in statistics? - ✔✔Taking more samples of the same size from
our sample.
✔✔What is the purpose of bootstrapping? - ✔✔To create an approximation of the
sampling distribution called the bootstrap distribution.
✔✔Does bootstrapping result in a true sampling distribution? - ✔✔No, it results in an
approximation called the bootstrap distribution.
✔✔7 steps to bootstrap - ✔✔1. randomly select an observation from the original
sample, which was drawn from the population
2. record observation value
3. replace that observation
4. repeat steps 1-3 until there are n observations, which forms a bootstrap
5. calculate bootstrap point estimate of the observations in the bootstrap sample
6. repeat 1-5 many times to create bootstrap distribution
7. calculate plausible range of values around our observed point estimate
✔✔What is a confidence interval? - ✔✔A range of plausible values for the population
parameter.
✔✔What percentage of observations are below the lower bound in a 95% confidence
interval? - ✔✔2.5%
✔✔What percentage of observations are below the upper bound in a 95% confidence
interval? - ✔✔97.5%
, ✔✔What is the first step in calculating a confidence interval? - ✔✔Arrange observations
in ascending order.
✔✔difference between rmse and rmspe - ✔✔rmse is for training set, rmspe is for testing
set
✔✔code lines for calculating rmse/rmspe - ✔✔fit |>
predict |>
bind_cols |>
metrics |>
filter |>
select |>
pull
✔✔how to make a data analysis reproducible - ✔✔- setting a random seed
- documenting each step during the analysis
✔✔markdown cell - ✔✔- for typing common text, like explanations
- help to organize and explain analysis
✔✔code cell - ✔✔- write and run code for R to use
- performing calculations, forming plots, etc
✔✔what does tbl(conn, "projects") do if conn is a connection to a database - ✔✔- Gets
the data table called "projects" from the database connection "conn"
- Useful because it creates a data frame in R that you can read and work with in R
✔✔why is pipe operator preferred - ✔✔- enhanced clarity when reading and writing the
code
- separates each function in order so steps are clear
✔✔what does facet_grid do - ✔✔splits a plot into multiple plots based on the values of
1-2 variables
✔✔when to use facet_grid - ✔✔to see how a relationship changes across different
categories
✔✔advantage of knn regression compared to linear reg - ✔✔- good fit for all sorts of
data, including nonlinear
- way easier to implement
✔✔disadvantage of knn reg compared to linear reg - ✔✔- slow when there is a lot of
data
- cannot make predictions outside of data range
- cannot interpret based off knn reg since it does not return an equation