Update app.py
Browse files
app.py
CHANGED
|
@@ -81,6 +81,7 @@ def compute_atr(ticker):
|
|
| 81 |
with st.spinner("Đang tải dữ liệu..."):
|
| 82 |
df = get_active_stocks()
|
| 83 |
df['ATR (14)'] = df['Symbol'].apply(compute_atr)
|
|
|
|
| 84 |
|
| 85 |
|
| 86 |
# Ứng dụng Streamlit
|
|
@@ -102,4 +103,4 @@ if st.button("Get Stocks Data"):
|
|
| 102 |
merged_df = pd.merge(df, stock_prices, on="Symbol", how="left")
|
| 103 |
|
| 104 |
st.dataframe(merged_df) # Hiển thị dữ liệu trên Streamlit
|
| 105 |
-
|
|
|
|
| 81 |
with st.spinner("Đang tải dữ liệu..."):
|
| 82 |
df = get_active_stocks()
|
| 83 |
df['ATR (14)'] = df['Symbol'].apply(compute_atr)
|
| 84 |
+
st.dataframe(df.dropna(subset=["ATR (14)"]).reset_index(drop=True))
|
| 85 |
|
| 86 |
|
| 87 |
# Ứng dụng Streamlit
|
|
|
|
| 103 |
merged_df = pd.merge(df, stock_prices, on="Symbol", how="left")
|
| 104 |
|
| 105 |
st.dataframe(merged_df) # Hiển thị dữ liệu trên Streamlit
|
| 106 |
+
|