Exercise

Density plots

Now you'll be making a third type of graph: a density plot. This type of plot allows us to visualize a distribution in a somewhat detailed way. You'll make two density plots using the People dataset; one for Height and one for Weight.

plotnine has been imported as p9.

Instructions 1/2

undefined XP
  • 1

    Use geom_density() to print a density plot of the Height for each Sample with a different fill for each Sample.

  • 2

    Print a density plot of the Weight of each Sample, with a different fill for each Sample.