I hereby claim:
- I am ranaroussi on github.
- I am ranaroussi (https://keybase.io/ranaroussi) on keybase.
- I have a public key ASA6RgWZK5het4zvK722ATQfHG0lqH6iUX2IQrwVtsuZ0Qo
To claim this, I am signing this object:
# mycode.py | |
import tradologics | |
def tradehook(payload): | |
payload = tradologics.parse(payload) | |
# is this a "data" payload? | |
if payload.event == "data": | |
for asset in payload.data: |
<?php | |
/** | |
* Multi-Server MySQLi class | |
* https://gist.github.com/ranaroussi/64a26c9a2ec6d69c62ba7c650f49a8a0 | |
* | |
* Copyright 2013-2020 Ran Aroussi | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at |
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import matplotlib as _mpl | |
import matplotlib.pyplot as _plt | |
from mpl_toolkits.mplot3d import Axes3D as _Axes3D | |
import numpy as _np | |
import pandas as _pd | |
import requests | |
def get_premarket(ticker): | |
""" | |
gets premarket prices from nasdaq | |
usage: | |
>> price, volume = get_premarket('spy') | |
""" |
import pandas as pd | |
def resample(data, resolution="1T", tz=None, ffill=True, dropna=False): | |
""" | |
>>> resample(df, '500K') # resample 500 ticks (by counting trades) | |
>>> resample(df, '500V') # resample ~500 volume (by counting volume) | |
""" | |
def __finalize(data, tz=None): | |
# figure out timezone |
#!/usr/bin/env python | |
import subprocess | |
import time | |
import sys | |
import logging | |
class Job: | |
""" | |
monitors that a job is running and executing it when it's not |
#!/usr/bin/env python | |
from dateutil.parser import parse as parse_date | |
import datetime | |
import requests | |
import pandas as pd | |
def get_contracts(url): | |
html = requests.get(url, timeout=5) |
{"lastUpload":"2022-03-29T10:27:38.273Z","extensionVersion":"v3.4.3"} |
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import pandas as pd | |
from urllib.parse import urlencode | |
class AlphaVantage(object): | |
def __init__(self, api_key): |