: A data analyst creates a bar chart with the diamonds dataset. They begin with the following line of code:ggplot(data = diamonds)What symbol should the analyst put at the end of the line of code to add a layer to the plot? View
: You are working with the penguins dataset. You create a scatterplot with the following lines of code:ggplot(data = penguins) +geom_point(mapping = aes(x = flipper_length_mm, y = body_mass_g)) +What code chunk do you add to the third line to save your plot as a png file with “penguins” as the file name? View
: A data analyst uses the annotate() function to create a text label for a plot. Which attributes of the text can the analyst change by adding code to the argument of the annotate() function? Select all that apply. View
: A data analyst creates a plot with the following code chunk:ggplot(data = penguins) +geom_jitter(mapping = aes(x = flipper_length_mm, y = body_mass_g))What does the geom_jitter() function do to the points in the plot? View
: You are working with the penguins dataset. You create a scatterplot with the following code:ggplot(data = penguins) +geom_point(mapping = aes(x = flipper_length_mm, y = body_mass_g))You want to highlight the different penguin species on your plot. Add a code chunk to the second line of code to map the aesthetic shape to the variable species.NOTE: the three dots (…) indicate where to add the code chunk.geom_point(mapping = aes(x = flipper_length_mm, y = body_mass_g, shape = species))Which penguin species does your visualization display? View
: The _____ aesthetic makes some points on a plot more transparent, or see-through, than others. View
: In ggplot2, which of the following aesthetic attributes can you use to map variables to points? Select all that apply. View
: You are working with the penguins dataset. You create a scatterplot with the following lines of code:ggplot(data = penguins) +geom_point(mapping = aes(x = flipper_length_mm, y = body_mass_g)) +What code chunk do you add to the third line to save your plot as a pdf file with “penguins” as the file name? View