Skip to content

Makes corner plots from MCMC samples using kernel density estimation.

License

Notifications You must be signed in to change notification settings

rubind/kde_corner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

kde_corner

Makes corner plots from MCMC samples using kernel density estimation. Reflects samples around minimum/maximum sample to better handle samples distributed against a parameter limit. I recommend setting bw_method to 0.1. The scipy default oversmoothes.

from kde_corner import kde_corner
kde_corner(orig_samples, labels, pltname)

Also useful for making your own contour plots outside of the corner plots:

import matplotlib.pyplot as plt
from kde_corner import run_2D_KDE

kernel_eval, levels, xvals, yvals, kernel_FN = run_2D_KDE(samples_of_x, samples_of_y, contours = [0.317311, 0.0455003], steps = 100)
plt.contourf(xvals, yvals, kernel_eval, levels = levels)

About

Makes corner plots from MCMC samples using kernel density estimation.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages