diff --git a/interactive_examples/streamlit_app.py b/interactive_examples/streamlit_app.py index 4b5a5da..2d515d4 100644 --- a/interactive_examples/streamlit_app.py +++ b/interactive_examples/streamlit_app.py @@ -1500,7 +1500,7 @@ def color_chg(val): c = "green" if val > 0 else ("red" if val < 0 else "grey") return f"color: {c}; font-weight: bold" - st.dataframe(df.style.applymap(color_chg, subset=["Change", "Change %"]), + st.dataframe(df.style.map(color_chg, subset=["Change", "Change %"]), use_container_width=True) @@ -1799,7 +1799,7 @@ def colour_status(val): if "PRE" in str(val).upper(): return "color: #f39c12; font-weight: bold" return "" - st.dataframe(df.style.applymap(colour_status, subset=["Status"]), + st.dataframe(df.style.map(colour_status, subset=["Status"]), use_container_width=True)