Recall & Review
beginner
What function in R is used to add a main title to a plot?
The
title() function is used to add a main title to a plot in R.Click to reveal answer
beginner
How do you add labels to the x-axis and y-axis in an R plot?
You can add labels to the x-axis and y-axis using the
xlab and ylab arguments inside the plot() function or by using the title() function with xlab and ylab arguments.Click to reveal answer
beginner
What argument inside the
plot() function controls the main title?The
main argument inside plot() controls the main title of the plot.Click to reveal answer
intermediate
How can you add a subtitle to a plot in R?
You can add a subtitle using the
sub argument inside the plot() function or by calling title(sub = "Your subtitle") after the plot.Click to reveal answer
beginner
What is the difference between
main and sub in R plotting?main sets the main title at the top of the plot, while sub sets a subtitle below the plot.Click to reveal answer
Which argument adds a main title directly inside the
plot() function?✗ Incorrect
The
main argument inside plot() adds the main title.How do you add a label to the x-axis in a plot?
✗ Incorrect
xlab sets the label for the x-axis.Which function can add a title after a plot is created?
✗ Incorrect
title() adds or modifies titles after the plot is drawn.What does the
sub argument do in R plotting?✗ Incorrect
sub adds a subtitle below the plot.If you want to label the y-axis, which argument do you use?
✗ Incorrect
ylab sets the label for the y-axis.Explain how to add a main title, x-axis label, and y-axis label to a plot in R.
Think about the arguments inside the plot() function.
You got /4 concepts.
Describe the difference between the 'main' and 'sub' arguments in R plotting.
Consider where the text appears on the plot.
You got /3 concepts.