All Questions
23
questions
0
votes
2
answers
778
views
continuous legend in ggplot2 and smooth contour lines
I am handling this data:
data.mi10 =
structure(list(Days = c(0, 40.5555555555556, 81.1111111111111,
121.666666666667, 162.222222222222, 202.777777777778, 243.333333333333,
283.888888888889, 324....
0
votes
1
answer
472
views
Why my plot's legend in ggplot2, doesn't show minimum and maximum value? It is showing a continuous value but not max and min?
ggplot(data=raster)+geom_raster(aes(x=x,y=y,fill=elevation))
now the legend by the plot, does not show the numbers for min and max values? what is the solution??
4
votes
1
answer
1k
views
How to make continuous legend in ggplot2?
I have little query regarding the legend in ggplot2. How can I make legend in a continuous level from the attached code. In this code the legend is in discrete form I want to make it in continuous ...
1
vote
2
answers
388
views
Adding a customized legend to a R raster spplot map
I would like to ask you for a few advices on a R cartography with Raster / spplot I am currently working on. I am a novice so I apologize in advance should the methods I used to be not at all optimal!
...
0
votes
1
answer
198
views
Combining rasters' legends in R language
Sorry for the evidently stupid question I haven't be able to solve, even after googleing for a while. Let's suppose the following situation, where I have two rasters with overlapping but different ...
0
votes
1
answer
451
views
Customizing Raster Labeling in LeafLet R
I have a raster layer with cell value ranging from 1 to 68, each number representing a different land cover type. how can i do it? I tried labelformat>>> transform. So far I can only work for ...
0
votes
0
answers
309
views
Adjusting the gap between colorkeys/colorbars/legends and the plot using levelplot or spplot
I plotted a raster data using levelplot
> library(raster)
> ras > raster("DEM.tif")
> spplot(S_dub, colorkey = list(space ="right",height=1, width=1, hjust = .3),
col.regions = ...
0
votes
1
answer
145
views
Plot "boolean" raster and add NA-Values to legend
I have a raster with values that are either 1 or NA. By default the plot(raster_1)-call gives me a continuous legend. What I actually want is a simple categorical legend with two entries and colors. ...
0
votes
1
answer
666
views
Plot discrete Raster data in R
I am able to plot but not satisfying results can be seen. It's because most of my value are within a close range seen in frequency plot. I don't know how to plot with such discrete data Data.
How ...
1
vote
0
answers
130
views
ggplot legend - how to change the colour spread?
I would like to change the spread display of the legend bar as on the jpeg below. In example 1, I'd like to display the "100" threshold value in the middle of the legend bar. In example 2, I'd like to ...
0
votes
0
answers
227
views
Legend labels of a NDVI image using R
I create an NDVI image from Landsat 5 image, using the NDVI function that is shown below. My problem is that I can´t see the legend labels when I plot the NDVI file.
1. NDVI function (For Landsat ...
0
votes
1
answer
421
views
Specifying different breakpoints of legends for raster in the same plot
If I want to provide my own classification of legend while plotting a raster, I could do this:
library(raster)
data(volcano)
volcanoR <- raster(volcano)
breakpoints <- c(94,100,120,140,160,180,...
1
vote
0
answers
1k
views
using layout to plot rasters with a common legend
Follow-up to this question. I am trying to plot 4 different rasters with a common scale (legend). I have managed to do it but now I want to plot them in the same graphic device, with the scale showing ...
1
vote
1
answer
860
views
R raster plot legend labels not aligning to breaks
This one is driving me crazy and I can't seem to hone in on it. Maybe someone else has had this issue. I am plotting a raster and plotting its legend separately. The legend axis labels will not ...
1
vote
0
answers
254
views
Add a legend to a google map obtained with dismo gmap R
[![require(raster)
require(dismo)
oc_go<-gmap(extent(c(10042219 ,19646634,-7110934,1881964)),type='terrain')
plot(oc_go)
... add another layer
legend("bottom", legend = c(" 1", " 2"," 3"," 4"," ...