Last active
February 26, 2020 09:42
-
-
Save dpoulopoulos/ece43bb9674c2a1afd1779e56b4591bb to your computer and use it in GitHub Desktop.
Load wiki movie and English first names data set.
This file contains hidden or 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
| import pandas as pd | |
| # load Wikipedia Movie Plots Dataset | |
| df = pd.read_csv('wiki_plots.csv') | |
| # load the English names dataset | |
| names_df = pd.read_csv('first_names.all.txt', names=['names'], header=0) | |
| # keep only the relevant columns | |
| df = df[['Title', 'Plot']] | |
| # sample 50% of the movies | |
| df = df.sample(frac=.5) | |
| # visualise the dataset | |
| df.head() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment