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
#! usr/bin/python | |
#Filename: rsquery2.py | |
import re, urllib, time | |
rsnumbers = [] | |
f = open('ancestral0624', 'a') | |
urltest = re.compile | |
prefix = "http://www.ncbi.nlm.nih.gov/projects/SNP/snp_ref.cgi?rs=" | |
rsn = open("snplist") |
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
from itertools import groupby | |
try: | |
xrange | |
except: | |
xrange = range | |
maxwt = 80 | |
#weight, weight, value to me | |
groupeditems = ( |
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
* {margin: 0; padding: 0;} | |
body{ | |
background: url('fakeexcel.png'); | |
} | |
.container { | |
padding: 200px; | |
text-align: center; | |
} |
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
"""Split up a pdf, add an image, recombine pdf""" | |
from pyPdf import PdfFileWriter, PdfFileReader | |
from random import random | |
import argparse | |
def main(): | |
parser = argparse.ArgumentParser(description = """Generate new pdf file | |
based on length of existing pdf""") | |
parser.add_argument('input_paper', help = """Input pdf of interest""") |
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
import pip | |
from subprocess import call | |
for dist in pip.get_installed_distributions(): | |
call('pip install --upgrade ' + dist.project_name, shell = True) |
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
from pywhois import whois | |
import argparse | |
parser = argparse.ArgumentParser(description= """whois lookup script""") | |
parser.add_argument('url', help = "URL of interest") | |
args = parser.parse_args() | |
print whois(args.url) |
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
import tweepy | |
from random import randrange | |
auth = tweepy.OAuthHandler('API Key', 'API secret') | |
auth.set_access_token('Access token', 'Access token secret') | |
api = tweepy.API(auth) | |
sleep(randrange(0,3600) |
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
Date | Brand | Mileage | Cost | Grade | Amount | TotalCost | |
---|---|---|---|---|---|---|---|
1/3/2014 | 76 | 43159 | 3.499 | 87 | 4.985 | 17.44 | |
1/13/2014 | Arco | 43415 | 3.29 | 87 | 9.205 | 30.28 | |
1/18/2014 | Shell | 43655 | 3.499 | 87 | 9.521 | 33.31 | |
1/22/2014 | Costco | 43938 | 3.179 | 87 | 9.28 | 29.5 | |
1/28/2014 | 76 | 44201 | 3.499 | 87 | 9.263 | 32.41 | |
2/15/2014 | 76 | 44434 | 3.499 | 87 | 9.434 | 33.01 | |
3/5/2014 | Shell | 44664 | 3.699 | 87 | 9.801 | 36.25 | |
3/16/2014 | 76 | 44917 | 3.519 | 87 | 9.014 | 31.72 | |
3/21/2014 | 7-11 (Citgo) | 45179 | 3.699 | 87 | 9.014 | 33.34 |
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
id | pieces | price | collection | |
---|---|---|---|---|
75059 | 3296 | 299.99 | Star Wars | |
10221 | 3152 | 399.99 | Star Wars | |
75037 | 178 | 14.99 | Star Wars | |
75035 | 99 | 12.99 | Star Wars | |
10188 | 3803 | 399.99 | Star Wars | |
75036 | 83 | 12.99 | Star Wars | |
75034 | 100 | 12.99 | Star Wars | |
10240 | 1559 | 199.99 | Star Wars | |
10225 | 2127 | 179.99 | Star Wars |
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
import argparse | |
import datetime as dt | |
import json | |
import pandas as pd | |
import numpy as np | |
from ggplot import * | |
parser = argparse.ArgumentParser(description = """Yearly summary trends for | |
LibraryThing JSON data""") | |
parser.add_argument('json', help = "JSON file from LibraryThing") |
OlderNewer