# Contour plot of density function

**URL:** <https://discourse.julialang.org/t/contour-plot-of-density-function/7806>\
**Category:** Visualization\
**Tags:** question\
**Created:** [December 16, 2017, 11:51am UTC](https://discourse.julialang.org/t/contour-plot-of-density-function/7806 "2017-12-16T11:51:48Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Post date:** [December 16, 2017, 3:15pm UTC](https://discourse.julialang.org/t/contour-plot-of-density-function/7806/3 "2017-12-16T15:15:40Z")

</div>

Sure; but the question is how to **plot** contours nicely without binning and/or sampling 😉

I realized that to determine [HPD](https://en.wikipedia.org/wiki/Credible_interval) cutoffs, I need to sample anyway. Then I can make a really dense grid, and just use `contour`.

There are some hints [here](https://discourse.julialang.org/t/implicit-plot-with-plots/6585) about what I want, but ATM just using `contour` on a very dense grid is probably the easiest solution.

---

_[View the full topic](https://discourse.julialang.org/t/contour-plot-of-density-function/7806)._
