Guest User

Untitled

a guest
Jul 18th, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.23 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Leaflet Map with Heatmap Demo </title>
  5. <meta charset="utf-8" />
  6. <link
  7. rel="stylesheet"
  8. href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css"
  9. />
  10. </head>
  11. <body>
  12. <div id="map" style="width: 100%; height: 600px"></div>
  13.  
  14. <script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"> </script>
  15. <script src="http://leaflet.github.io/Leaflet.heat/dist/leaflet-heat.js"> </script>
  16. <script>
  17.  
  18. var quakePoints = [
  19. [-41.5396,174.1242,10.7345],
  20. [-38.8725,175.9561,3.6901],
  21. [-41.8992,174.3117,5.6968]
  22. ];
  23.  
  24. var map = L.map('map').setView([-41.5546,174.146], 10);
  25. mapLink =
  26. '<a href="http://openstreetmap.org">OpenStreetMap</a>';
  27. L.tileLayer(
  28. 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
  29. attribution: '&copy; ' + mapLink + ' Contributors',
  30. maxZoom: 18,
  31. }).addTo(map);
  32.  
  33. var heat = L.heatLayer(quakePoints,{
  34. radius: 20,
  35. blur: 15,
  36. maxZoom: 17,
  37. }).addTo(map);
  38.  
  39. </script>
  40. </body>
  41. </html>
  42.  
  43. val someDF = Seq(
  44. (-41.5396,174.1242,10.7345),
  45. (-38.8725,175.9561,3.6901),
  46. (-41.8992,174.3117,5.6968)
  47. ).toDF("lat", "long", "value")
Add Comment
Please, Sign In to add comment