Skip to content

Instantly share code, notes, and snippets.

@evilying
Created July 7, 2018 19:15
Show Gist options
  • Save evilying/b7a9fcb15e2b5a5be3b5f7bfed24fbf0 to your computer and use it in GitHub Desktop.
Save evilying/b7a9fcb15e2b5a5be3b5f7bfed24fbf0 to your computer and use it in GitHub Desktop.

Typically, we’ll set the pd.get_dummies() argument drop_first to True to avoid the so-called “dummy variable trap,” in which independent variables being closely correlated violates assumptions of independence in regression.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment