4 ms·
I like seaborn's jointplot()[1] function for generating plots like this. I actually prefer the "hexagonal bin" plot, but jointplot() can also do kernel density
by alexhutcheson 8y ago
I like seaborn's jointplot()[1] function for generating plots like this. I actually prefer the "hexagonal bin" plot, but jointplot() can also do kernel density estimation like this post does.
Hexbin example: https://seaborn.pydata.org/examples/hexbin_marginals.html https://seaborn.pydata.org/examples/hexbin_marginals.html
KDE example: https://seaborn.pydata.org/examples/joint_kde.html 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 https://seaborn.pydata.org/generated/seaborn.jointplot.html