Introduction to R
- 134Unfamiliar
- 0Learning
- 0Familiar
- 0Mastered
134 questions
- 1The programming language introduced in the course as arguably the language of data science is_____.
Hint
It is a free, open-source language commonly used for statistical computing.
Answer
R
- 2Compared with commercial software packages, R is especially accessible because it is_____and open source.
Hint
There is no purchase price for the core software.
Answer
free
- 3R is optimized for_____operations, allowing users to work with entire rows or tables without explicitly writing loops.
Hint
Think of operations applied to collections of values at once.
Answer
vector
- 4The large, supportive group that contributes examples, help, and new developments to R is the R_____.
Hint
It includes users and developers who support one another.
Answer
community
- 5R's third-party extensions are distributed as bundles of code called_____.
Hint
They add functions and capabilities to the base software.
Answer
packages
- 6The official R website for statistical computing is located at_____.
Hint
It is the home page for the R project.
Answer
r-project.org
- 7The comprehensive archive used to download R and many R packages is abbreviated_____.
Hint
The abbreviation refers to the Comprehensive R Archive Network.
Answer
CRAN
- 8When downloading R, the cloud mirror is convenient because it automatically directs users to the best available_____.
Hint
It is a geographically distributed download location.
Answer
mirror
- 9An R source or script file normally uses the file extension_____.
Hint
It consists of the letter associated with the language and a file-extension marker.
Answer
.R
- 10In the native R application, the window where code is written is called the source or_____window.
Hint
It contains the commands that make up a program.
Answer
script
- 11The R window that displays the results of commands is the_____window.
Hint
It shows text output from executed code.
Answer
console
- 12In an R script, a line beginning with a pound sign or hashtag is a_____line and is not executed as code.
Hint
It provides notes or explanations for the programmer.
Answer
commented
- 13In RStudio, the pane that stores variables currently available for use is the_____pane.
Hint
It represents the current collection of objects and variables.
Answer
environment
- 14RStudio provides a more_____interface by organizing the script, console, environment, and plots in one window.
Hint
The opposite would be having many separate windows.
Answer
unified
- 15RStudio standardizes keyboard commands across Mac, Windows, and Linux by providing consistent_____.
Hint
These are keyboard instructions used to perform operations.
Answer
commands
- 16A package that makes working with R more organized and easier is called_____.
Hint
It is an application that sits on top of R.
Answer
RStudio
- 17Base packages are installed with R but are not necessarily_____by default.
Hint
Installation makes a package available on the computer; this action makes it available in the current session.
Answer
loaded
- 18Contributed or third-party packages must generally be downloaded, installed, and then_____separately.
Hint
This makes the package's functions accessible to the current R session.
Answer
loaded
- 19The package manager used in the course to install and load other packages is_____.
Hint
Its name refers to managing packages.
Answer
Pacman
- 20Installing a package makes it available on the hard drive, whereas_____makes it accessible to current routines.
Hint
This action occurs within the current R session.
Answer
loading
- 21The function_____
libraryloads a package without displaying a confirmation message, whereasrequiregives amessage.Hint
It tells the user that the package has been successfully loaded.
Answer
confirmation
- 22The package used for manipulating data frames is_____.
Hint
Its name begins with a shortened form of data.
Answer
dplyr
- 23The package used for cleaning up information is_____.
Hint
Its name relates to making data tidy.
Answer
tidyr
- 24The package used for working with strings or text information is_____.
Hint
Its name resembles the word string.
Answer
stringr
- 25The package used for manipulating date information is_____.
Hint
Its name is associated with dates and time.
Answer
lubridate
- 26The package used for importing and exporting data is_____.
Hint
Its name is described as R input and output.
Answer
rio
- 27The package that creates interactive applications that can be installed on websites is_____.
Hint
It is commonly used to build interactive web applications in R.
Answer
Shiny
- 28The package used to create interactive notebooks or rich documents is_____.
Hint
It combines R code, results, and formatted explanatory text.
Answer
R Markdown
- 29The default R command for basic graphical exploration is_____.
Hint
It adapts its output to the data types and number of variables supplied.
Answer
plot
- 30When a categorical variable such as species is supplied alone to_____
plot, R produces a simplechart.Hint
The chart displays counts for categories.
Answer
bar
- 31When a quantitative variable is supplied alone to the default_____
plotcommand, R generally produces aplot.Hint
The horizontal axis represents observation or row index in this case.
Answer
scatter
- 32When a categorical variable and a quantitative variable are supplied to_____
plot, R commonly chooses aplot.Hint
This graphic compares distributions across categories.
Answer
box
- 33When two quantitative variables are supplied to_____
plot, R chooses a properplot.Hint
Each point represents the joint position of two measurements.
Answer
scatter
- 34A plot of an entire data frame containing several quantitative variables produces a matrix of_____plots.
Hint
The matrix shows pairwise relationships among variables.
Answer
scatter
- 35In a_____
plotcommand, the argumentpch = 19selects a solidsymbol.Hint
It specifies the point character used for observations.
Answer
circle
- 36In a plot command,_____
colspecifies theof plotted elements.Hint
It can be assigned a color name or a hexadecimal code.
Answer
color
- 37The argument_____
lwdcontrols theof a plotted line.Hint
Increasing it makes a line visually thicker.
Answer
linewidth
- 38The basic graphic most appropriate for a categorical variable is a_____chart.
Hint
It summarizes category frequencies with rectangular bars.
Answer
bar
- 39Before making a bar chart from raw categorical observations, the data should first be converted into a summary_____.
Hint
It contains the count for each category.
Answer
table
- 40The most basic graphic for a quantitative, scaled, interval, or ratio variable is a_____.
Hint
It groups numerical values into bins.
Answer
histogram
- 41When examining a histogram, analysts should inspect its shape, gaps, outliers, and_____.
Hint
This concerns whether high and low scores are balanced around the center.
Answer
symmetry
- 42In a histogram, the vertical axis usually displays the frequency or_____of observations in each bin.
Hint
It tells how many observations fall into a group.
Answer
count
- 43The_____
breaksargument in a histogram suggests the number of.Hint
These are the intervals into which observations are grouped.
Answer
bars
- 44A histogram can display proportions instead of frequencies by setting its output to_____.
Hint
This expresses values relative to the total distribution.
Answer
density
- 45A plot made from multiple versions of the same chart on the same scale is called small_____.
Hint
The term refers to repeated panels used for comparison.
Answer
multiples
- 46A scatterplot is primarily used to visualize the association between two_____variables.
Hint
Both variables are measured numerically.
Answer
quantitative
- 47If the spread of points changes substantially across the x-axis, the scatterplot shows_____.
Hint
The term describes unequal variance or a fanning pattern.
Answer
heteroscedasticity
- 48Overlaying plots increases information_____by placing complementary views in the same space.
Hint
It means more information is shown in a given amount of space.
Answer
density
- 49When overlaying plots, the recommended rule is to use views that complement rather than_____with one another.
Hint
The graphics should remain coherent and readable.
Answer
compete
- 50The command that adds a normal density curve to an existing plot is_____.
Hint
It draws a mathematical function over the current graph.
Answer
curve
- 51A kernel density estimator is nonparametric because it follows the_____of the observed data.
Hint
It can contain more curves than a fixed bell-shaped model.
Answer
distribution
- 52A rug plot marks each individual observation with a small vertical_____beneath the graph.
Hint
It provides a one-dimensional display of every data point.
Answer
line
- 53The R function that gives counts for categories and numerical summaries for quantitative variables is_____.
Hint
It provides a quick descriptive overview.
Answer
summary
- 54For a categorical variable,_____
summaryreports the frequency orof each category.Hint
In the iris species example, each category has 50 observations.
Answer
count
- 55For a quantitative variable,_____
summaryreports the minimum, first quartile,, mean, third quartile, and maximum.Hint
It is the middle value in an ordered distribution.
Answer
median
- 56Comparing the median and mean can provide clues about distributional_____.
Hint
A difference between these measures may indicate asymmetry.
Answer
skewness
- 57The_____
summaryfunction can be applied to an entire dataat once.Hint
This is R's spreadsheet-like two-dimensional structure.
Answer
frame
- 58The more detailed descriptive function used in the course comes from the contributed package_____.
Hint
It is commonly used for psychological and descriptive statistics.
Answer
psych
- 59Unlike_____
summary,describeis intended primarily forvariables rather than categories.Hint
It reports statistics such as standard deviation, skewness, and kurtosis.
Answer
quantitative
- 60Among other statistics,_____
describereports sample size, mean, standard deviation, median, skewness, kurtosis, and standard.Hint
These quantify uncertainty around estimates.
Answer
errors
- 61The recommended order for exploratory analysis is graphical summaries first and numerical summaries_____.
Hint
Pictures are used before precise numerical descriptions.
Answer
later
- 62Selecting cases allows an analyst to focus an analysis on particular_____.
Hint
These are individual observations or rows of data.
Answer
cases
- 63Cases can be selected by category, by value on a scaled variable, or by_____methods simultaneously.
Hint
The third option combines categorical and numerical conditions.
Answer
both
- 64In R, two equal signs, written as_____
==, test whether values are.Hint
This is a comparison operator, not an assignment operator.
Answer
equivalent
- 65The ampersand operator combines multiple selection conditions by requiring that they are both_____.
Hint
It represents a logical AND relationship.
Answer
true
- 66The R data structure consisting of one or more values in one dimension is a_____.
Hint
Imagine the values arranged in a straight line.
Answer
vector
- 67All elements in an R vector must have the same_____.
Hint
A vector cannot mix arbitrary numeric, character, and logical elements without conversion.
Answer
data type
- 68A one-element vector is still considered a vector in R rather than a_____.
Hint
Some other programming contexts use this term for one number.
Answer
scalar
- 69A matrix is a two-dimensional structure organized into rows and_____.
Hint
It has a rectangular layout.
Answer
columns
- 70All values in an R matrix must have the same_____.
Hint
Matrices cannot normally contain arbitrary mixtures of data types.
Answer
class
- 71An array is like a matrix but has_____or more dimensions.
Hint
A matrix has two dimensions; an array extends beyond that.
Answer
three
- 72A data frame is a two-dimensional structure whose columns may contain different types but must have the same_____.
Hint
Each column must contain the same number of observations.
Answer
length
- 73The R structure most analogous to a spreadsheet is a data_____.
Hint
It has rows and columns with potentially different column types.
Answer
frame
- 74The most flexible R data structure is the_____.
Hint
It can contain elements of different classes, lengths, and structures.
Answer
list
- 75The process of changing a data object from one type or structure to another is called_____.
Hint
It can change a character to logical or a matrix to a data frame.
Answer
coercion
- 76When incompatible values are combined automatically, R generally coerces them to the least restrictive or most_____type.
Hint
Character data can encompass numeric and logical values after conversion.
Answer
general
- 77R uses_____precision as the default representation for numeric values.
Hint
It is also called double precision.
Answer
double
- 78The function_____
as.integerconverts a value to thedata type.Hint
This type represents whole-number values.
Answer
integer
- 79The function_____
as.numericconverts character representations such as "1" and "2" intovalues.Hint
The quotation marks are removed after successful conversion.
Answer
numeric
- 80The less-than sign followed by a dash,_____
<-, is R'soperator.Hint
It assigns a value to a variable.
Answer
assignment
- 81A factor is an attribute of a vector that specifies possible values and their_____.
Hint
Factors can encode category order as well as category names.
Answer
order
- 82A factor records its possible categories as_____.
Hint
The factor example had three of these corresponding to 1, 2, and 3.
Answer
levels
- 83The function used to convert an existing variable into a factor is_____.
Hint
It begins with the standard coercion prefix.
Answer
as.factor
- 84Factor labels must be supplied in the same_____as the numerical codes they represent.
Hint
Code 1 receives the first label, code 2 the second, and so on.
Answer
order
- 85Although a labeled factor may display words such as Mac OS or Windows, its underlying values may remain_____codes.
Hint
The structure output still shows values such as 1, 2, and 3.
Answer
numerical
- 86The function that creates a sequence from a starting value to an ending value is the_____operator.
Hint
It is placed between two numbers, as in 0 to 10.
Answer
colon
- 87The function used to generate more specifically controlled sequences is_____.
Hint
It is short for sequence.
Answer
seq
- 88The function used to combine or collect values into a vector is_____.
Hint
Its name is short for concatenate.
Answer
c
- 89The function that reads data values interactively from the console is_____.
Hint
It lets the user type values and finish by pressing Enter twice.
Answer
scan
- 90The function used to repeat values or groups of values is_____.
Hint
Its name is short for replicate.
Answer
rep
- 91CSV stands for comma-separated_____.
Hint
It is a plain-text representation of tabular data.
Answer
values
- 92The file extension commonly associated with Excel workbooks is_____.
Hint
It is the later Excel format mentioned in the lesson.
Answer
.xlsx
- 93JSON is an abbreviation for JavaScript Object_____.
Hint
It is a common format for web data.
Answer
Notation
- 94The package that combines many R import functions into one utility with consistent syntax is_____.
Hint
Its name refers to R input and output.
Answer
rio
- 95The rio function used to import files of different formats is_____.
Hint
The same command can read CSV, TXT, and XLSX files.
Answer
import
- 96The R function that opens a spreadsheet-like view of an object is_____.
Hint
It is written with a capital first letter.
Answer
View
- 97The built-in function for reading a tab-delimited text file is_____.
Hint
It may require a header and a tab separator to be specified.
Answer
read.table
- 98The built-in function for reading comma-separated data is_____.
Hint
The file format is encoded in the function name.
Answer
read.csv
- 99When possible, Excel data should be exported as tab-delimited or comma-separated text before importing into_____.
Hint
The recommendation is to avoid directly reading Excel files when possible.
Answer
R
- 100Hierarchical clustering searches for observations that are similar, or “like with_____.”
Hint
The phrase describes grouping similar cases together.
Answer
like
- 101The clustering distance measure used in the example is_____distance.
Hint
It measures straight-line distance in multidimensional space.
Answer
Euclidean
- 102Hierarchical clustering does not require the analyst to set the number of groups in_____.
Hint
The number of clusters can be examined after the hierarchy is constructed.
Answer
advance
- 103In divisive clustering, all observations begin in one group and are gradually_____apart.
Hint
This is the opposite direction from agglomerative clustering.
Answer
split
- 104In agglomerative clustering, observations begin separately and are selectively put_____.
Hint
The process builds larger groups from individual cases.
Answer
together
- 105The tree-like graph produced by hierarchical clustering is called a_____.
Hint
Its branches show when observations or clusters split or join.
Answer
dendrogram
- 106A clustering solution is valid only for the specific observations and_____supplied to the analysis.
Hint
Changing the measurements used can change the resulting groups.
Answer
variables
- 107Principal component analysis is also known as_____reduction.
Hint
It reduces the number of dimensions while retaining important information.
Answer
dimensionality
- 108PCA begins by finding a regression-like direction and measuring the_____distance from each point to it.
Hint
This is not the ordinary vertical regression residual.
Answer
perpendicular
- 109Centering data moves variables so their_____are zero.
Hint
Subtracting the average produces this result.
Answer
means
- 110Scaling data in PCA places variables on a common scale with unit_____.
Hint
This prevents variables with larger ranges from dominating the analysis.
Answer
variance
- 111The R function used in the example to compute principal components is_____.
Hint
Its name combines principal components with a compact function name.
Answer
prcomp
- 112A PCA summary produces the same number of components as there are original_____.
Hint
Each original dimension contributes to the transformed representation.
Answer
variables
- 113A scree plot helps evaluate how much of the original_____each principal component explains.
Hint
Large components account for more variation in the data.
Answer
variance
- 114A PCA rotation value can be interpreted approximately as the association or_____between an original variable and a component.
Hint
It describes how strongly a variable relates to a principal component.
Answer
correlation
- 115A biplot in the example displays the first_____principal components.
Hint
It is a two-dimensional representation.
Answer
two
- 116Regression uses multiple predictor variables to predict one particular_____variable.
Hint
It is the variable being explained or predicted.
Answer
outcome
- 117In the regression example, the variable being predicted is whether a judge is worthy of_____.
Hint
It concerns whether the judge should remain on the bench.
Answer
retention
- 118The R function_____
lmis short formodel.Hint
It is the basic function used for linear regression.
Answer
linear
- 119In an R model formula, the tilde means “is predicted by” or “as a function of” the_____on its right.
Hint
These variables are used to explain the outcome.
Answer
predictors
- 120Entering all predictor variables into one regression equation at the same time is called_____entry.
Hint
All predictors enter together rather than in selected steps.
Answer
simultaneous
- 121The regression coefficient representing the predicted value when all predictors are zero is the_____.
Hint
It is the constant term in the regression equation.
Answer
intercept
- 122The probability cutoff highlighted for statistical significance in the regression output is_____.
Hint
It is commonly written as .05 in statistical output.
Answer
0.05
- 123The statistic describing how well the predictors collectively explain the outcome is multiple_____squared.
Hint
It is commonly written with a superscript 2.
Answer
R
- 124The table used to summarize variance components in regression is the_____table.
Hint
Its name stands for analysis of variance.
Answer
ANOVA
- 125A confidence interval gives a lower and upper range for a coefficient, commonly using a_____percent interval in the example.
Hint
The interval leaves 2.5 percent in each tail.
Answer
95
- 126The differences between observed and model-predicted values are called_____.
Hint
They represent prediction errors for individual cases.
Answer
residuals
- 127The regression method described as least absolute shrinkage and selection operator is abbreviated_____.
Hint
It is a regularized regression method.
Answer
lasso
- 128The regression method that stands for least angle regression is abbreviated_____.
Hint
Its name is also the name of the package used in the example.
Answer
Lars
- 129Python is presented as another popular language for data science that also functions as a general-purpose_____language.
Hint
It can be used beyond statistical and data-analysis tasks.
Answer
programming
- 130Understanding how to design high-quality data visualizations is presented as a separate issue from simply using R's visualization_____.
Hint
R provides many of these for creating graphics.
Answer
packages
- 131Machine learning focuses on processing large amounts of data and obtaining_____from one set of data that can be applied to others.
Hint
The result should generalize beyond the original data.
Answer
predictions
- 132The annual conference for R users is called useR! and the exclamation point is part of its official_____.
Hint
It is not merely punctuation added informally.
Answer
name
- 133Local groups for R users are commonly abbreviated_____.
Hint
The abbreviation stands for R user groups.
Answer
RUGs
- 134The unofficial day suggested for celebrating R is September_____.
Hint
It coincides with International Talk Like a Pirate Day.
Answer
19

Ask anything
We've read this whole study set, so questions about it get the best answers.