Exercise

  1. Now suppose we want to use color to represent the different regions. In this case which of the following is most appropriate:

    1. Adding a column called color to murders with the color we want to use.
    2. Because each label needs a different color we map the colors through the color argument of the local aes .
    3. Use the color argument in ggplot.
    4. Because we want all colors to be blue, we do not need to map colors, just use the color argument in geom_label.


    Store your answer in question_1.

  2. Rewrite the code from the previous question to make the labels’ color be determined by the state’s region. Store the resulting ggplot object in p

    Note

    Make sure to only apply the color mapping to the geom layer. In this case, there will be no visible difference, but when we add more layers in the future we don’t want the color mapping to apply to those too.