Skip to content

Instantly share code, notes, and snippets.

@nikkisharma536
Created June 11, 2020 09:34
Show Gist options
  • Save nikkisharma536/4efff71449ff6724e7fba5f4c3f75116 to your computer and use it in GitHub Desktop.
Save nikkisharma536/4efff71449ff6724e7fba5f4c3f75116 to your computer and use it in GitHub Desktop.
Streamlit select box widget
metrics =['total_cases','new_cases','total_deaths','new_deaths','total_cases_per_million','new_cases_per_million','total_deaths_per_million','new_deaths_per_million','total_tests','new_tests','total_tests_per_thousand','new_tests_per_thousand']
cols = st.selectbox('Covid metric to view', metrics)
# let's ask the user which column should be used as Index
if cols in metrics:
metric_to_show_in_covid_Layer = cols
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment