R - hist plot colours by quantile
问题 I am trying to do a simple hist plot and colour the bins by quantile . I was wondering why when the bins size change the colours gets all messed up. Maybe I am not doing it right from the beginning. The quantiles are quantile(x) 0% 25% 50% 75% 100% 0.00 33.75 58.00 78.25 123.00 Then I am setting the colours with the quantile values k = ifelse(test = x <= 34, yes = "#8DD3C7", no = ifelse(test = (x > 34 & x <= 58), yes = "#FFFFB3", no = ifelse(test = (x > 58 & x <= 79), yes = "#BEBADA", no =