Creating Heatmap from Scratch in Python (2018)
geodose.com
geodose.com
Hexbin example: https://seaborn.pydata.org/examples/hexbin_marginals.html
KDE example: https://seaborn.pydata.org/examples/joint_kde.html
If you are doing any exploratory analysis using scatterplots, I highly recommend that you also generate hexbin plot or heatmap. Far too often it turns out all of the points are concentrated in a small area of the plot, but that's not always apparent on a scatterplot.
[1] https://seaborn.pydata.org/generated/seaborn.jointplot.html
x_grid=np.arange(x_min-h,x_max+h,grid_size)
y_grid=np.arange(y_min-h,y_max+h,grid_size)
where h is a small constant, and the range ends are the min/max of the data. In general, this will result in rectangular pixels, which you probably don't want.In your example, even for a small geographic area, a degree of longitude will typically translate to a smaller distance than a degree of latitude, so as you say you can't treat them the same.
If you're overlaying datashader on a map, use the projected coordinates as input (to both datashader and/or any heatmap).
https://github.com/rraks/sigcatch
Open to contributions.
There is no good entrypoint into the documentation, it just starts to tell me about projection details. The documentation outline is a list of the code functions with no clear point to start or indication which places might be good to start at.
I also can't find any examples for quick demonstration and trying. (edit: I found them after clicking all the links. Well... it's in the middle of a list of details I'm not interesting in and says 'Using cartopy with matplotlib'. Oh, at the bottom there is a link with more examples which I could find neither in the index nor in the outline... urgh.)
basemap's website also has a lot of problems, but it is a lot easier to use and we are lazy.
But again, it is not very obvious that the gallery includes sample code, and that you have to click the pictures to get there.
I know about projections, I just don't care enough for that to be the first thing I see. When I start out I just want to make a basic map, fast. (edit: That's actually typical of many open source projects: They start by telling you about all the fancy tech behind it and let you figure out for yourself how to reach your goal/what goal you can actually reach with it.)
Well, enough of whining about the page to probably unrelated people. I actually found it a sign of trustworthyness if a project page looks chaotic and full of bad copy. It means they're not a startup and/or trying to sell something, usually. (This is just too much though, it is not just not new and fancy with no calls to action and pop-ups for mailing lists, it actively tries to hinder you in doing what you came to do.)