Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import matplotlib.pyplot as plt
- import seaborn as sns
- wavg = movies_ranked.sort_values('weighted_average', ascending=False)
- plt.figure(figsize=(16,6))
- ax = sns.barplot(x=wavg['weighted_average'].head(10), y=wavg['original_title'].head(10), data=wavg, palette='deep')
- plt.xlim(6.75, 8.35)
- plt.title('"Best" Movies by TMDB Votes', weight='bold')
- plt.xlabel('Weighted Average Score', weight='bold')
- plt.ylabel('Movie Title', weight='bold')
- plt.savefig('best_movies.png')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement