Skip to content

Instantly share code, notes, and snippets.

@ravishchawla
Created February 27, 2019 17:58
Show Gist options
  • Save ravishchawla/1a9a4bc9b7b7af3fdeec6e0048d24944 to your computer and use it in GitHub Desktop.
Save ravishchawla/1a9a4bc9b7b7af3fdeec6e0048d24944 to your computer and use it in GitHub Desktop.
AirBnB post: PCA results
principal_weights = pd.DataFrame(pca.components_,columns=l_X.columns)
p_c_1 = principal_weights.iloc[0]
print(p_c_1.sort_values()[0:10])
print(p_c_1.sort_values()[-10:])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment