From the course: R Essential Training: Wrangling and Visualizing Data

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Using colors in R

Using colors in R

From the course: R Essential Training: Wrangling and Visualizing Data

Start my 1-month free trial

Using colors in R

- [Instructor] The best way to understand your data is to actually look at it, and it's also the best way to share your insights with other people. One thing that's going to help there is a little bit of design sense and colors are going to be the easiest and possibly the most effective way to do that. Fortunately, R makes it relatively easy to work with colors in a number of different ways. What I want to do is show you some of the options you have for working with colors. I'm going to start by installing a few packages, I have pacman there, then I'm going to bring in the tidy version of the datasets, but let's come down here and put in just a microscopic dataset that I'm just going to call X, it's six numbers, and we're going to use that to make a bar chart, so I'm going to use the default barplot command. Here's my bar chart, and truthfully, the gray is perfectly fine for exploratory purposes, so I don't mess with it…

Contents