Created
March 2, 2015 14:24
-
-
Save brandonmburroughs/f7ed7c523733191e7911 to your computer and use it in GitHub Desktop.
This code generates your Data Science profile plot as described in "Doing Data Science" by Cathy O'Neil and Rachel Schutt.
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
# -*- coding: utf-8 -*- | |
""" | |
Title: Data Science Profile | |
Author: Brandon M. Burroughs | |
Description: This code generates your Data Science profile plot as described in | |
"Doing Data Science" by Cathy O'Neil and Rachel Schutt. | |
Feel free to contact me with any questions, suggestions, or corrections! | |
Email: brandonmburroughs@gmail.com | |
LinkedIn: https://www.linkedin.com/in/brandonmburroughs | |
Twitter: @ToTheBurroughs | |
""" | |
import pandas as pd | |
import matplotlib.pyplot as plt | |
# Your info goes here. | |
name = 'Brandon' # Put your name here. | |
bar_data_labels = ['Mathematics', 'Statistics', 'Computer Science', 'Machine Learning', 'Communication', 'Visualization', 'Domain'] # These are the Data Science areas suggested in Doing Data Science. | |
bar_data = [75, 80, 50, 60, 80, 40, 30] # Rate each skill from 0 to 100. | |
bar_data = pd.DataFrame(bar_data) # Put your data into a dataframe | |
# Create the plot | |
bar_data.plot(kind='bar', ylim=[0,100], title="%s's Data Science Profile" % name, legend=False, figsize=[10,6]).set_xticklabels(labels=bar_data_labels, rotation=45) | |
plt.xlabel('Skill') | |
plt.ylabel("Rating (0 to 100)") | |
plt.savefig('%s_Data_Science_Profile.png' % name) # Save the plot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment