I needed help knowing how to associate colors with values. For example, I have a vector for colors and values as follows i.e.
cols <- c("red", "gray60")
and
numEra <- c(values)
numEra
[1] 1 1 1 2 2 2
How do I associate these values with the colors "red" and "gray60" ??
Maybe you want to use
cutlike this:Created on 2022-10-01 with reprex v2.0.2
So each number is now associated with a color.