Spaces:
Running
Running
James McCool
commited on
Commit
·
636dd7e
1
Parent(s):
5898d60
Refactor app.py to remove duplicate tab definitions for Scoring Percentages, Player ROO, and Optimals, ensuring cleaner code organization and preventing potential conflicts in tab functionality.
Browse files
app.py
CHANGED
@@ -55,6 +55,8 @@ st.markdown("""
|
|
55 |
}
|
56 |
</style>""", unsafe_allow_html=True)
|
57 |
|
|
|
|
|
58 |
@st.cache_resource(ttl = 60)
|
59 |
def init_baselines():
|
60 |
collection = db["Player_Range_Of_Outcomes"]
|
@@ -123,8 +125,6 @@ with st.container():
|
|
123 |
with col2:
|
124 |
site_var = st.selectbox("What site do you want to view?", ('Draftkings', 'Fanduel'), key='site_var')
|
125 |
|
126 |
-
tab1, tab2, tab3 = st.tabs(["Scoring Percentages", "Player ROO", "Optimals"])
|
127 |
-
|
128 |
with tab1:
|
129 |
st.header("Scoring Percentages")
|
130 |
with st.expander("Info and Filters"):
|
@@ -481,8 +481,4 @@ with tab3:
|
|
481 |
data=convert_df_to_csv(summary_df),
|
482 |
file_name='MLB_seed_frame_frequency.csv',
|
483 |
mime='text/csv',
|
484 |
-
)
|
485 |
-
|
486 |
-
if "initial_rerun_done" not in st.session_state:
|
487 |
-
st.session_state.initial_rerun_done = True
|
488 |
-
st.rerun()
|
|
|
55 |
}
|
56 |
</style>""", unsafe_allow_html=True)
|
57 |
|
58 |
+
tab1, tab2, tab3 = st.tabs(["Scoring Percentages", "Player ROO", "Optimals"])
|
59 |
+
|
60 |
@st.cache_resource(ttl = 60)
|
61 |
def init_baselines():
|
62 |
collection = db["Player_Range_Of_Outcomes"]
|
|
|
125 |
with col2:
|
126 |
site_var = st.selectbox("What site do you want to view?", ('Draftkings', 'Fanduel'), key='site_var')
|
127 |
|
|
|
|
|
128 |
with tab1:
|
129 |
st.header("Scoring Percentages")
|
130 |
with st.expander("Info and Filters"):
|
|
|
481 |
data=convert_df_to_csv(summary_df),
|
482 |
file_name='MLB_seed_frame_frequency.csv',
|
483 |
mime='text/csv',
|
484 |
+
)
|
|
|
|
|
|
|
|