We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Good morning,
I am looking at all the examples in order to make an accident map of my city, but there's no way to show the heatmap in my leaflet map (last version).
For some reason I create the HeatmapOverlay, set all parameters, load all data, but nothing is showed.
I don't see any reason for that behavior then I like to know if that plug-in is still working.
CODE (basic implementation code):
let pl_Cal_ly_calor = new HeatmapOverlay({ radius: 20, maxOpacity: .9, blur: .75, scaleRadius: true, useLocalExtrema: true, latField: "lat", lngField: "lng", valueField: "value" })
mymap.addLayer(pl_Cal_ly_calor)
let testData = {max: 100, data: [{lat: 41.72950, lng: 1.83130, value: 100}]} pl_Cal_ly_calor.setData( testData )
The text was updated successfully, but these errors were encountered:
https://github.com/pa7/heatmap.js/blob/master/plugins/leaflet-heatmap/leaflet-heatmap.js#L184 Although it's said "experimential... not ready.", it is actually working but setData not.
I can set the max value and draw the points like this:
layer.setData({max:200, data:[]}); layer.addData(data.data);
As a Leaflet Layer extension, I think addData should simply wrap https://github.com/pa7/heatmap.js/blob/develop/src/data.js#L123 and setData should be replaced by a function like setStyle for updating the options where max and min also belong to.
BTW, if you use "scaleRadius: true", you may need to zoom to see the huge rendering. #273
Sorry, something went wrong.
No branches or pull requests
Good morning,
I am looking at all the examples in order to make an accident map of my city, but there's no way to show the heatmap in my leaflet map (last version).
For some reason I create the HeatmapOverlay, set all parameters, load all data, but nothing is showed.
I don't see any reason for that behavior then I like to know if that plug-in is still working.
CODE (basic implementation code):
let pl_Cal_ly_calor = new HeatmapOverlay({
radius: 20,
maxOpacity: .9,
blur: .75,
scaleRadius: true,
useLocalExtrema: true,
latField: "lat",
lngField: "lng",
valueField: "value"
})
mymap.addLayer(pl_Cal_ly_calor)
let testData = {max: 100, data: [{lat: 41.72950, lng: 1.83130, value: 100}]}
pl_Cal_ly_calor.setData( testData )
The text was updated successfully, but these errors were encountered: