Skip to content

Instantly share code, notes, and snippets.

Michael DeFelice mtdefelice

Block or report user

Report or block mtdefelice

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View s+s-matching.py
'''
The 'students.csv' and 'startups.csv' files represent the Typeform exports for each and are saved to this script's directory. All student resumes have been downloaded and stored in the 'student_resumes/' folder.
'startups_x.csv' is a parsed version of 'startups.csv' that has been extended with the job descriptions & content from the supplied *.pdf
'''
import glob
import textract
import re
@mtdefelice
mtdefelice / mote_carlo_forecast.py
Last active Nov 30, 2018
Random Walks - A Monte Carlo simulation to forecast (poorly) a stock's performance (seriously, *do not* take financial advice from this script or it's output!)
View mote_carlo_forecast.py
import numpy as np, pandas as pd
import quandl
from matplotlib.ticker import FuncFormatter, MultipleLocator
import matplotlib.pyplot as plt
plt.style.use ('ggplot')
# For better feeds, create an account on quandl.com and include your API key in the call
df = quandl.get ('WIKI/AAPL', start_date = '2017-01-01', rows = 250)
@mtdefelice
mtdefelice / saas_company-data_generator.py
Last active Nov 28, 2018
Random Walks - Acme Widget Co. SaaS Data Generator. Supports multiple subscription types.
View saas_company-data_generator.py
import numpy as np, pandas as pd
import matplotlib.pyplot as plt
plt.style.use ('ggplot')
# Note the first at 0 is a free trial ... As upgrades are considered advancing through this array, please ensure the pricing increases throughout the list
subscription_prices = [0, 5, 10, 15, 20 ]
# These need to sum to 1
subscription_pvals = [0.80, 0.10, 0.06, 0.02, 0.02]
sub_n = len (subscription_pvals)
@mtdefelice
mtdefelice / get-email_provider.py
Created Mar 19, 2018
From STDIN, get an email provider from a list of domains or email addresses.
View get-email_provider.py
import sys
import subprocess
import re
_map = {
'.gmail.com.': 'Gmail',
'.aspmx.l.google.com.': 'G Suite',
'.mail.protection.outlook.com.': 'Office 365',
'.mail.eo.outlook.com.': 'Office 365',
'.emailsrvr.com.': 'RSE/HEX',
View keybase.md

Keybase proof

I hereby claim:

  • I am mtdefelice on github.
  • I am mtdefelice (https://keybase.io/mtdefelice) on keybase.
  • I have a public key ASBs7pY5Wf8z_e0ddCytY8xvjxLaXYMGJCp_UbVs43u5dAo

To claim this, I am signing this object:

You can’t perform that action at this time.