https://trac.pythonprogramminghelp.com/how-to-quickly-pearsonian-x2-tests/