Please look at the color legend of the image:
- 0-3 with 0.5 interval,
- 3-9 with 3 interval,
- 9-10 with 1 interval,
- 10-20 with 2 interval and
- 20-70 with 50 interval.
The legend scale was uniformly graduated but labelled as per breaks given. Can we get such legends in R 'Raster - plot'? or any other packages in R?
I have tried in R (raster) and got this image:
In this, the legend is not looking good. I need the a legend like in first image.
The R codes I used are following,
library(raster) data=raster("dfile.nc") # MODIS-AQUA satellite data breakpoints=c(0:0.2, 0.21:2,2.01:5,15) colpatt=rev(colorRampPalette(c("red", "orange", "blue"))(6)) plot(data,breaks=breakpoints, col=colpatt)