Source: https://www.princeton.edu/~otorres/LogitR101.pdf