This file contains hidden or 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
| """ | |
| @authors: Christopher, Lorenzo | |
| """ | |
| import requests | |
| import json | |
| from utils import companies | |
| def get_income_statement(company): | |
| resp = requests.get(f"https://financialmodelingprep.com/api/v3/company/profile/{company}") |
This file contains hidden or 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
| """ | |
| @authors: Christopher, Lorenzo | |
| """ | |
| import requests | |
| import json | |
| from utils import companies | |
| def get_cash_flow(company): | |
| resp = requests.get(f"https://financialmodelingprep.com/api/v3/financials/cash-flow-statement/{company}") |
This file contains hidden or 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
| """ | |
| @authors: Lorenzo, Christopher | |
| """ | |
| import requests | |
| import json | |
| from utils import companies | |
| def get_income_statement(company): | |
| resp = requests.get(f"https://financialmodelingprep.com/api/v3/financials/income-statement/{company}") |
This file contains hidden or 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
| """ | |
| @authors: Lorenzo, Christopher | |
| """ | |
| import requests | |
| import json | |
| from utils import companies | |
| def get_balance_sheet(company): |
This file contains hidden or 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
| """ | |
| @authors: Lorenzo, Christopher | |
| """ | |
| import json | |
| # FOR BACKTESTING IN 2015 HIDE COMPANIES: HLT, FCAU, QSR, BAH | |
| DATA_DIR = "data" | |
| companies = [ |
This file contains hidden or 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
| """ | |
| @authors: Lorenzo, Christopher | |
| """ | |
| from utils import read_income_statement, read_balance_sheet, read_cash_flow, companies | |
| def fcff_forecast(comp): | |
| last_year = 2014 | |
| income = read_income_statement(comp, 2009, 2014) | |
| ebitp = read_income_statement(comp, 2009, 2014) |
This file contains hidden or 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
| """ | |
| @authors: Christopher, Lorenzo | |
| """ | |
| from utils import read_income_statement, read_balance_sheet, read_cash_flow, read_company_profile, companies | |
| def fcff_forecast(comp): | |
| last_year = 2019 | |
| income = read_income_statement(comp, 2014, 2019) | |
| ebit = read_income_statement(comp, 2014, 2019) |