Reputation: 10273
I would like to use multhist from the plotrix library to plot interlaced histograms. I need to specify the colors of each of these histograms. I tried this:
a <- c(1,2,3)
b <- c(1,1,2)
c <- c(1,1,1)
l <- list(1,b,c)
mycolors <- list("red", "green", "blue")
multhist(l, col=mycolors)
but it doesn't like the way I have specified the colors. Is there a way to do this?
Upvotes: 0
Views: 752
Reputation: 10273
Turns out it is as easy as this
multhist(l, col=c("red","green","blue"))
Upvotes: 2