Skip to content

Instantly share code, notes, and snippets.

View Thuruv's full-sized avatar

Thuruv Thuruv

View GitHub Profile
# -*- coding: utf-8 -*-
import json
import os
import logmatic
import logging
from logging.config import dictConfig
import requests
from http import HTTPStatus
import re
from kiteconnect import KiteConnect
@Thuruv
Thuruv / GoogleSpreadsheets.py
Created August 23, 2016 19:57 — forked from cspickert/GoogleSpreadsheets.py
Export a Google Spreadsheet using python.
#!/usr/bin/python
import re, urllib, urllib2
class Spreadsheet(object):
def __init__(self, key):
super(Spreadsheet, self).__init__()
self.key = key
class Client(object):
@Thuruv
Thuruv / pareto.py
Created July 28, 2016 15:44 — forked from jesseh/pareto.py
Pareto Chart with Matplotlib
import pandas as pd
import matplotlib.pyplot as plt
def combined_label(perc, tot):
"""
Format a label to include by Euros and %.
"""
return "{0:,.0f}k EUR, {1:.0f}%".format(perc * tot / 1000, perc * 100)
def cost_cum(data, focus, subject):
@Thuruv
Thuruv / 0_reuse_code.js
Last active August 29, 2015 14:20
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console