Know your problem
Know your data
Visualize your data – numerical variables
Work with your chart
15. Chart aesthetics: adding color
Check yourself


Always make your data stand out.

We have our data and its relationship sorted. Now we can work on the appearance of the chart – making it visually attractive and easy to understand. At this point, everything apart from the trend line is black or grey. The data points almost blend in with other elements. To make the data stand out, we need to change the color of the points.

To do this, use the geom_point() command, which looks like:


The color you choose will go in the "fill" variable. Remember to use a color name recognized by R.


Change the color of the points.

You can use any color in our Color Card located in the right sidebar. Click on a color, and you will see its full name. Write the name where the your_color placeholder text is.

When you're done, press Run and Check Code button.

Stuck? Here's a hint!

You should write:

geom_point(color = "deepskyblue3")