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
# HOW TO PRINT BUNDLE SYMBOLS | |
import os | |
from pandas import Timestamp | |
from zipline.data.bundles import load | |
now = Timestamp.utcnow() | |
bundle = load('US_stock_bundle', os.environ, now) | |
symbols = set(str(asset.symbol) | |
for asset in bundle.asset_finder.retrieve_all( |
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/env python | |
# Simpson Diversity Index | |
# http://en.wikipedia.org/wiki/Diversity_index | |
# modified from Shannon Diversity Index implementation by audy | |
# https://gist.github.com/audy/783125 | |
# https://gist.github.com/audy | |
def simpson_di(data): |
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 time | |
import random | |
import math | |
import numpy as np | |
import logbook | |
log = logbook.Logger('Optimization') | |
from neuronquant.network.transport import ZMQ_Dealer |