Session Ready
Exercise

One-sample t-test

In this exercise, you will perform a one-sample t-test using the ttest_1sample() function. Using eudata, a dataset of country-level statistics, you'll be looking at the sex ratios found in the population of European countries. You'll use a one sample t-test to determine if the mean sex ratio found among European countries differs significantly from 50-50. First, you'll make some plots, then you'll perform your test. pandas, scipy.stats, and plotnine have been loaded into the workspace as pd, stats, and p9.

Instructions 1/2
undefined XP
  • 1
  • 2
  • Run the provided code, specifying the correct DataFrame, to print a density plot of Sex_ratio.