Update app.py
Browse files
app.py
CHANGED
|
@@ -1082,8 +1082,8 @@ for company in companies:
|
|
| 1082 |
df_c = pd.merge(df_c, prices[company], on='date_merge', how='inner')
|
| 1083 |
|
| 1084 |
# Strategy A: Sentiment
|
| 1085 |
-
df_c['StrategyA_Daily'] = 0
|
| 1086 |
-
df_c['StrategyA_Cumulative'] = 0
|
| 1087 |
for i in range(1, len(df_c)):
|
| 1088 |
score = df_c.loc[i,'Confidence']
|
| 1089 |
pct = df_c.loc[i,'PctChangeDaily'] if pd.notnull(df_c.loc[i,'PctChangeDaily']) else 0
|
|
@@ -1150,8 +1150,7 @@ demo = gr.Interface(
|
|
| 1150 |
choices=companies,
|
| 1151 |
value=["Microsoft"], # default
|
| 1152 |
label="Select Companies",
|
| 1153 |
-
multiselect=True,
|
| 1154 |
-
searchable=True # abilita la ricerca testuale
|
| 1155 |
)
|
| 1156 |
],
|
| 1157 |
outputs=[
|
|
|
|
| 1082 |
df_c = pd.merge(df_c, prices[company], on='date_merge', how='inner')
|
| 1083 |
|
| 1084 |
# Strategy A: Sentiment
|
| 1085 |
+
df_c['StrategyA_Daily'] = 0.0
|
| 1086 |
+
df_c['StrategyA_Cumulative'] = 0.0
|
| 1087 |
for i in range(1, len(df_c)):
|
| 1088 |
score = df_c.loc[i,'Confidence']
|
| 1089 |
pct = df_c.loc[i,'PctChangeDaily'] if pd.notnull(df_c.loc[i,'PctChangeDaily']) else 0
|
|
|
|
| 1150 |
choices=companies,
|
| 1151 |
value=["Microsoft"], # default
|
| 1152 |
label="Select Companies",
|
| 1153 |
+
multiselect=True,
|
|
|
|
| 1154 |
)
|
| 1155 |
],
|
| 1156 |
outputs=[
|