| from tabs.plot_by_columns import plot_by_columns |
| from tabs.volume_profile import volume_profile |
| from datetime import time |
| import streamlit as st |
|
|
|
|
| st.markdown('# Plotting Dashboard') |
|
|
| st.sidebar.title("Meta Parameters") |
| st.sidebar.caption("Choose Meta Parameters here.") |
|
|
| ticker_name = st.sidebar.text_input('Enter the ticker name') |
| given_date = st.sidebar.text_input('Enter the date') |
| strategy_timeframe = st.sidebar.text_input('Enter the strategy timeframe') |
| vp_timeframe = st.sidebar.text_input('Enter the volume profile timeframe') |
|
|
| by_columns_tab, strategy_tab, volume_profile_tab = st.tabs(["plot columns by each other", "plot strategy", |
| "volume profile"]) |
|
|
| with by_columns_tab: |
| if ticker_name != '' and given_date != '' and strategy_timeframe != '': |
| plot_by_columns(ticker=ticker_name, date=given_date, timeframe=strategy_timeframe, session=st) |
| else: |
| st.markdown('### No Dataframe to Show Yet!') |
|
|
| with volume_profile_tab: |
| st.markdown('#### Interval of Volume Profile') |
| vp_interval = st.slider("Choose the interval of volume Profile", value=(time(12, 45), time(16, 0))) |
|
|
| if ticker_name != '' and given_date != '' and strategy_timeframe != '' and vp_timeframe != '': |
| volume_profile(ticker=ticker_name, date=given_date, strategy_timeframe=strategy_timeframe, |
| volume_profile_timeframe=vp_timeframe, interval=vp_interval, session=st) |
|
|
| else: |
| st.markdown('### No Dataframe to Show Yet!') |