Skip to content

Instantly share code, notes, and snippets.

@erykml
Created July 28, 2022 20:26
Show Gist options
  • Save erykml/af79822ccd0f255ea130ef5bd13c4605 to your computer and use it in GitHub Desktop.
Save erykml/af79822ccd0f255ea130ef5bd13c4605 to your computer and use it in GitHub Desktop.
X_1 = pd.DataFrame(
data=pd.get_dummies(X.index.month, drop_first=True, prefix="month")
)
X_1.index = X.index
X_1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment