Dear All. Kindly assist me with the proper code for the following. I have converted the dose to factor and grouped it into 5 levels. I need to assign a color code to each of the levels and use is for spatial mapping. Thank you
ggplot(Mrima, mapping=aes(x=lon,y=lat))+ geom_point(data=Mrima, aes(colour=factor(dose), cut(dose,br=c(0,60,120,360,600,5144)))) + scale_color_manual(my_col, values = c("#D01556#", "#DF785B","EFDC60", "#B5D374","#7CCA89"),breaks=waiver(), aesthetics =c("colour","fill")) This is the error I am getting Error: Insufficient values in manual scale. 1806 needed but only 5 provided. -- The University of Nairobi is ISO 9001:2015 certified. Website: http://www.uonbi.ac.ke/ <http://www.uonbi.ac.ke/> Facebook: https://www.facebook.com/uonbi.ac.ke <https://www.facebook.com/uonbi.ac.ke> Twitter: @uonbi https://twitter.com/uonb <https://twitter.com/uonb> [[alternative HTML version deleted]] _______________________________________________ R-sig-Geo mailing list R-sig-Geo@r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-geo