Spaces:
Running
Running
Jon Solow
commited on
Commit
•
b0bf07f
1
Parent(s):
45e7011
Lower limit for regex search field rather than categorical
Browse files- src/streamlit_filter.py +1 -1
src/streamlit_filter.py
CHANGED
@@ -47,7 +47,7 @@ def filter_dataframe(df: pd.DataFrame, force_on: bool = False, force_on_columns:
|
|
47 |
for column in to_filter_columns:
|
48 |
left, right = st.columns((1, 20))
|
49 |
# Treat columns with < 17 unique values as categorical
|
50 |
-
if isinstance(df[column].dtype, pd.CategoricalDtype) or df[column].nunique() <
|
51 |
user_cat_input = right.multiselect(
|
52 |
f"Values for {column}",
|
53 |
df[column].unique(),
|
|
|
47 |
for column in to_filter_columns:
|
48 |
left, right = st.columns((1, 20))
|
49 |
# Treat columns with < 17 unique values as categorical
|
50 |
+
if isinstance(df[column].dtype, pd.CategoricalDtype) or df[column].nunique() < 17:
|
51 |
user_cat_input = right.multiselect(
|
52 |
f"Values for {column}",
|
53 |
df[column].unique(),
|