Created
March 2, 2020 13:15
-
-
Save Alakhator/245b7f297665bf0b1c6238eb57e58fc3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%%timeit | |
data.groupby('C')["A"].mean() | |
mean =data.groupby('C')["A"].mean().rename("N").reset_index() | |
df_1 = data.merge(mean) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment