(df)
| 1 | import streamlit as st |
| 2 | |
| 3 | def create_region_selector(df): |
| 4 | regions = sorted(df['REGIONAL_OFFICE_NAME'].unique()) |
| 5 | |
| 6 | col1, col2 = st.columns([3, 1]) |
| 7 | |
| 8 | with col1: |
| 9 | selected_region = st.selectbox( |
| 10 | "Select NHS Region", |
| 11 | regions, |
| 12 | key="region_selector" |
| 13 | ) |
| 14 | |
| 15 | with col2: |
| 16 | st.metric("Total Regions", len(regions)) |
| 17 | |
| 18 | return selected_region |
no outgoing calls
no test coverage detected