rajat5ranjan commited on
Commit
bb7fddb
·
verified ·
1 Parent(s): fef6025

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -22
app.py CHANGED
@@ -20,6 +20,8 @@ import yfinance as yf
20
  from datetime import datetime, timedelta
21
  from newsapi import NewsApiClient
22
  import json
 
 
23
  import altair as alt
24
 
25
  st.set_page_config(layout="wide")
@@ -234,28 +236,6 @@ if ticker_user!="":
234
  )
235
 
236
  st.altair_chart(chart, use_container_width=True)
237
-
238
-
239
-
240
- # Extract counts only
241
- counts = {k: v for k, v in summary_dict.items() if k != "RECOMMENDATION"}
242
- max_value = max(counts.values())
243
- st.markdown(f"### Current Recommendation: **{summary_dict['RECOMMENDATION']}**")
244
-
245
- # Optional emoji for better visual cue
246
- emoji_map = {
247
- "BUY": "🟢",
248
- "SELL": "🔴",
249
- "NEUTRAL": "🟡"
250
- }
251
-
252
- for rec, count in counts.items():
253
- emoji = emoji_map.get(rec, "")
254
- st.write(f"{emoji} **{rec}**: {count}")
255
- st.progress(count / max_value)
256
-
257
-
258
- # st.dataframe(analysis_summary.summary, use_container_width=True)
259
 
260
  # --- Row 2: Oscillators + Moving Averages ---
261
  # col3, col4 = st.columns(2)
 
20
  from datetime import datetime, timedelta
21
  from newsapi import NewsApiClient
22
  import json
23
+ import pandas as pd
24
+ import numpy as np
25
  import altair as alt
26
 
27
  st.set_page_config(layout="wide")
 
236
  )
237
 
238
  st.altair_chart(chart, use_container_width=True)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
239
 
240
  # --- Row 2: Oscillators + Moving Averages ---
241
  # col3, col4 = st.columns(2)