Embed map of observations

just so you know:

  1. if you visit the Leaflet website, it’ll give you a pretty good tutorial for how to set up a basic map
  2. you can visit the iNaturalist API page to see how to work with their observation tiles, polygon tiles, and UTFGrids
  3. if you only need to see the observation markers or heatmap but don’t need to be able to click them to trigger some sort of action (like opening up the observation details), then you don’t need the UTFGrid code (which simplifies things greatly)
  4. iNaturalist doesn’t serve up basemap tiles via their API. so you’ll need to pick your own set of basemaps. my code example includes references to many XYZ tilesets that i think are free to use (in some situations), but if you expect to get a lot of hits, you may want to get proper commercial access to some basemaps.
  5. GBIF (which aggregates data from iNaturalist and other data sources) can also provide data via XYZ tiles. see https://forum.inaturalist.org/t/create-a-live-map-service-for-arcmap-and-or-google-earth-with-inat-data-and-links/1512/2. it looks like they serve up some basemap tiles, too.