Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -493,14 +493,14 @@ if 'data' in st.session_state:
|
|
| 493 |
help="Select to apply Simple Moving Average (SMA) to the stock price."
|
| 494 |
)
|
| 495 |
|
| 496 |
-
|
| 497 |
-
|
| 498 |
-
|
| 499 |
-
|
| 500 |
-
|
| 501 |
-
|
| 502 |
-
|
| 503 |
-
|
| 504 |
|
| 505 |
# EMA with tooltip
|
| 506 |
use_ema = st.sidebar.checkbox(
|
|
|
|
| 493 |
help="Select to apply Simple Moving Average (SMA) to the stock price."
|
| 494 |
)
|
| 495 |
|
| 496 |
+
sma_period = st.sidebar.number_input(
|
| 497 |
+
'SMA Period',
|
| 498 |
+
min_value=1,
|
| 499 |
+
value=st.session_state.get('sma_period', 50),
|
| 500 |
+
step=1,
|
| 501 |
+
disabled=not use_sma,
|
| 502 |
+
help="Specify the period (in days) for the SMA."
|
| 503 |
+
)
|
| 504 |
|
| 505 |
# EMA with tooltip
|
| 506 |
use_ema = st.sidebar.checkbox(
|