Running a Basic Statistical Test in Python on a Real World Example

The problem: Is scoring really higher in the NFL this year?

People love football because it's exciting. Unlike a TV show or movie you really have no idea what's going to happen. There are no scriptwriters purposely manipulating you. The good guys do not always win! This makes it so much sweeter when your team pulls off a tremendous comeback than when Captain America finally figures out the right guy to punch until the good guys win.

Obligatory let Russ cook
  1. My null hypothesis was that average scoring was no different from last year to this year. My alternative hypothesis was that it had increased. The Null hypothesis is the status quo, while your alternative hypothesis is based on something being different from the null hypothesis based on your observations
  2. I chose a standard significance of 0.05. This is your chance of returning a false positive or rejecting the null hypothesis when it is true. A lower alpha level reduces the risk of this but what I was doing was not especially risky. No one is going to lose money or be affected medically if I’m wrong. So going with the commonly used level of 0.05 seemed like a fine choice.
  3. To calculate the test statistic I will need some data.
A basic dist plot of the two years scoring averages, 2020 in orange, 2019 in blue



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store