Session Ready
Exercise

Plot a CDF

The distribution of income in almost every country is long-tailed; that is, there are a small number of people with very high incomes.

In the GSS dataset, the variable 'realinc' represents total household income, converted to 1986 dollars. We can get a sense of the shape of this distribution by plotting the CDF.

Instructions
100 XP
  • Select 'realinc' from the gss dataset.
  • Make a Cdf object called cdf_income.
  • Create a plot of cdf_income using .plot().