Welcome in the density plot section of the gallery. If you want to know more about this kind of chart, visit data-to-viz.com. If you're looking for a simple way to implement it in R, pick an example below.

Using the

`ggplot2`

libraryA density plot shows the distribution of a __numeric__ variable. In `ggplot2`

, the `geom_density()`

function takes care of the __kernel density estimation__ and plot the results. A common task in dataviz is to compare the distribution of several groups. The graph #135 provides a few guidelines on how to do so.