2

In the context of Markov Chain Monte Carlo, I want to plot the 2D posterior distribution for a parameter estimation problem using corner.corner. The figure that I have now looks like this:

example posterior pdf

In the contour plot, the contours are defined by probability quantiles, such that what is outside the contours has low probability.

I would like to know if it is possible to remove the samples in the background (i.e. the grey dots) outside of the probability contours.

Bremsstrahlung
  • 686
  • 1
  • 9
  • 23

1 Answers1

5

To remove the datapoints outside from contour, you have to plot_datapoints=False in corner.corner command.

I hope it will simply solve your issue.

  • This worked. I saw this kwarg in the corner.hist2d() function in the API documentation, but not for corner.corner. They must have forgotten to write it. – Bremsstrahlung Apr 03 '20 at 16:12