All Questions
14
questions
1
vote
0
answers
64
views
Add time slider for a stack of rasters
I'm looking for a static HTML solution (no Shiny) to incorporate a timeslider for raster data in a leaflet.
leaflet.extras2::addTimeslider() requires the data argument to be "a Simple Feature ...
0
votes
1
answer
34
views
How can you create heatmaps in R with leaflet from multiple csvs? Merging/resampling issue
I have been using this as an inspiration. I have c.400 GPS files with GPS positions in csv's, each csv has a file property that I want to retain to create heatmaps based on that property.
https://gis....
5
votes
1
answer
376
views
raster and polygons in leaflet, without raster interpolation
I'm trying to display several layers in leaflet (or mapview), one of which is a raster in EPSG:27700. The only way I manage to adequately overlay those layers is through the default latlong projection,...
2
votes
1
answer
255
views
Raster output from rasterized sf points does not align with points
I am trying to rasterize some points and am getting a mismatch between the points and the rasters despite the crs being the same. If I convert the raster to polygons it lines up perfectly with the sf ...
2
votes
1
answer
309
views
Issue plotting generated polygon grid to leaflet
I am trying to create a polygon grid to plot in leaflet, but am running into an error that I cannot seem to figure out:
library(leaflet)
library(raster)
library(sf)
library(rgdal)
r <- raster(ext =...
0
votes
1
answer
277
views
Loop over in leaflet
I have a code below, and I would like to forloop the overlayGroup by each cluster.
library(dplyr); library(leaflet); library(raster);library(htmltools)
cluster <- c("1st.C", "2nd.C&...
1
vote
0
answers
309
views
Overlay raster RGB and polygon layer in leaflet/mapview with custom CRS in R
I am trying to use R mapview/plainview or leaflet to display a raster RGB with a second layer that is a vector-based (spatial points or polygon) on top that I can toggle on an doff. It is important ...
6
votes
1
answer
1k
views
leaflet side-by-side for 2 raster images in R
{leaflet.extras2} implements the leaflet side-by-side plugin and provides this minimal example:
library(leaflet)
library(leaflet.extras2)
leaflet(quakes) %>%
addMapPane("left", zIndex =...
1
vote
0
answers
84
views
rasterFromXYZ projection is misaligned but drawing individual points lines up correctly
I have lat/lon data with a value for each coordinate. I am trying to create a raster layer to use in leaflet where the values are mapped to a palette.
mydata has 3 cols, x, y, z (where z is value)
...
0
votes
1
answer
776
views
Leaflet with Shiny - how to ensure maximum zoom in option for the user
For one of the map use case , need to provide maximum zoom in option for the user in shiny app. Have tried to explore some of the options as per below code. Wanted to understand if this is the maximum ...
3
votes
1
answer
353
views
Problem joining different SpatialPolygonsDataFrame objects in R
I have a shape file of towns in the north of Spain that I have to join into groups (municipalities or comarcas in Spanish). I've used st_union from the sf package to join them successfully (and each ...
1
vote
1
answer
964
views
How do i get mapview to plot my raster image with the same colors as plotRGB or plot
I have a raster file that I have exported from ArcGIS as a georeferenced tif file.
The raster will be used as a background map in mapview because the mapview background layers CartoDB.Positron, ...
2
votes
0
answers
1k
views
How do I add a raster to a leaflet map in r that nicely covers the land, and doesn't have gaps?
I have a dataset of several thousand geographical points, each assigned a cluster (in my reproducible example below I simplify this to 8 points). I want to color an entire global map (only the ...
5
votes
0
answers
449
views
How to project a raster + polygons in Lambert 93 with leaflet on R?
I'm trying to make a leaflet map in Lambert 93 (st_transform(2154)) composed of:
1. Polygons (France)
2. Raster Layer (Europe)
I can't understand why the following code is not working.
library(...