Starting from:

$29.99

CSCI297B Exercise 8 Solution

For this project, use the tidyverse library, which includes the mpg dataset.
For this project, you will turn in a single R markdown file, called exercise08.Rmd
1. Create a scatterplot of hwy vs. displ where the points are pink filled in triangles.
2. Why did the following code not result in a plot with blue points?
ggplot(mpg) +
geom_point(aes(x = displ, y = hwy, color = "blue"))
3. What does the stroke aesthetic do? What shapes does it work with? (Hint: use ?geom_point)
4. What happens if you map an aesthetic to something other than a variable name, likeaes(color = displ < 5)? Note, you’ll also need to specify x and y.
1

More products