[AstroPy] how to make density plot and contour via python?

John K. Parejko john.parejko@yale....
Thu Nov 1 10:32:47 CDT 2012


I am a big fan of the hexbin matplotlib module.

http://matplotlib.org/examples/pylab_examples/hexbin_demo.html

Setting mincnt=1 gets rid of the "last" contour, and you can change the alpha level to overlay histograms on the same plot and have underlying layers visible.

John

On 1Nov 2012, at 10:36, Adrian Price-Whelan wrote:

> Check out this example:
> http://micropore.wordpress.com/2011/10/01/2d-density-plot-or-2d-histogram/
> 
> And also this code:
> https://gist.github.com/3993992
> 
> - Adrian
> 
> On Nov 1, 2012, at 8:46 AM, gonghang.naoc wrote:
> 
>> hi,anybody knows the details?I have about 1e+7 discrete points. Thanks!
>> _______________________________________________
>> AstroPy mailing list
>> AstroPy@scipy.org
>> http://mail.scipy.org/mailman/listinfo/astropy
> 
> --
> Adrian Price-Whelan
> Department of Astronomy
> Columbia University
> 
> 
> 
> _______________________________________________
> AstroPy mailing list
> AstroPy@scipy.org
> http://mail.scipy.org/mailman/listinfo/astropy

--
*************************
John Parejko
john.parejko@yale.edu
http://www.astro.yale.edu/~jp727/
203 432-9759
JWG 465
Department of Physics
Yale University
New Haven, CT
**************************








More information about the AstroPy mailing list