mpl-scatter-density icon indicating copy to clipboard operation
mpl-scatter-density copied to clipboard

How to control the marker size in "scatter_density"?

Open WangYun1995 opened this issue 4 years ago • 5 comments

WangYun1995 avatar Feb 28 '21 08:02 WangYun1995

I have the same question?

mcolic avatar Mar 24 '21 22:03 mcolic

Hi, I just started to use this package as well. What do you mean with marker size? Do you mean how fine the grid is? There is a parameter called dpi which changes the grid size, see the two images bellow. The first one is with dpi=30, the second with dpi=20.

image image

scimax avatar May 29 '21 16:05 scimax

Hi, I just started to use this package as well. What do you mean with marker size? Do you mean how fine the grid is? There is a parameter called dpi which changes the grid size, see the two images bellow. The first one is with dpi=30, the second with dpi=20.

image image

Hi, @scimax How do the values of "density", i.e. color bar, change with dpi?

WangYun1995 avatar Jun 04 '21 13:06 WangYun1995

Well, due to the more coarse binning there are more scatterers in the bin with the highest intensity:

dpi=30 case: image dpi=20 case: image

scimax avatar Jun 04 '21 13:06 scimax

Thank you for your answer @scimax. By the way, if the units of x-coordinate and y-coordinate are kilometers, is there any way to express the density as "per square kilometers", i.e. km^{-2}?

WangYun1995 avatar Jun 06 '21 02:06 WangYun1995