diff --git a/requirements.txt b/requirements.txt index 9b12307..5a15114 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,3 +2,6 @@ numpy matplotlib streamlit scipy +hvplot +bokeh +holoviews diff --git a/st_runner.py b/st_runner.py index d24abb6..4dfc11a 100644 --- a/st_runner.py +++ b/st_runner.py @@ -21,9 +21,13 @@ for basename in os.listdir(folder): fnames.append(fname) # Make a UI to run different files. -files = {f.split("/")[-1].split(".")[0]: f for f in fnames} -filename = st.sidebar.selectbox("Select an app", list(files.keys())) -fname_to_run = files[filename] +def format_func(s): + return s.split("/")[-1].split(".")[0] + + +fname_to_run = st.sidebar.selectbox( + "Select an app", fnames, format_func=format_func +) # Create module from filepath and put in sys.modules, so Streamlit knows # to watch it for changes.