Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -18,8 +18,9 @@ stocks = ['AAPL', 'MSFT', 'AMZN', 'GOOGL', 'FB', 'BRK.B', 'JNJ', 'V', 'PG', 'JPM
|
|
18 |
sp500_averages_path = 'sp500_averages.csv'
|
19 |
|
20 |
def load_sp500_averages(filepath):
|
21 |
-
# Load
|
22 |
-
return pd.read_csv(filepath,
|
|
|
23 |
|
24 |
def fetch_stock_data(ticker_symbol):
|
25 |
# Fetch financial data for a single stock
|
|
|
18 |
sp500_averages_path = 'sp500_averages.csv'
|
19 |
|
20 |
def load_sp500_averages(filepath):
|
21 |
+
# Load the CSV without specifying an index column name
|
22 |
+
return pd.read_csv(filepath, header=0, names=['Ratio', 'Average']).set_index('Ratio')
|
23 |
+
|
24 |
|
25 |
def fetch_stock_data(ticker_symbol):
|
26 |
# Fetch financial data for a single stock
|