Last active
December 27, 2019 15:34
-
-
Save ShaneLee/d3dbde63094748aa387016c2e2022bff to your computer and use it in GitHub Desktop.
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
def get_data(stock): | |
data = pd.DataFrame() | |
if stock['type'] == 'index': | |
data = wb.DataReader(stock['ticker'], 'stooq', start=START_DATE)['Close'] | |
return get_simulation(data) | |
data = wb.DataReader(stock['ticker'], 'yahoo', start=START_DATE)['Adj Close'] | |
return get_simulation(data) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment