- Using the
mtcars
data, create a scatterplot of the fuel efficiency as a function of weight.
- Repeat the scatterplot, but make the points violet open squares of size 5.
- Repeat the scatterplot but with separate colors for cylinder levels.
- Why does the legend look like that? Fix it so there are separate colors for cylinder levels.
- Overlay separate regression lines for each cylinder level.
- Overlay a single firebrick regression line over the points with a firebrick1-colored confidence band.
- Plot the mean and standard error of the mean of fuel efficiency for each level of cylinder and color them sienna.