Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -971,10 +971,14 @@ if st.session_state.prediction_data is not None:
|
|
| 971 |
|
| 972 |
# 4️⃣ 轉換機率篩選
|
| 973 |
if enable_conversion_filter:
|
| 974 |
-
|
| 975 |
-
(filtered_df[
|
| 976 |
-
|
| 977 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 978 |
|
| 979 |
# ✅ 條件摘要顯示
|
| 980 |
st.markdown("#### 您的篩選條件為:")
|
|
|
|
| 971 |
|
| 972 |
# 4️⃣ 轉換機率篩選
|
| 973 |
if enable_conversion_filter:
|
| 974 |
+
conversion_mask = (
|
| 975 |
+
(filtered_df['Online_conversion_prob'] >= min_online_conv) |
|
| 976 |
+
(filtered_df['O2O_reservation_prob'] >= min_o2o_conv)
|
| 977 |
+
)
|
| 978 |
+
filtered_df = filtered_df[conversion_mask]
|
| 979 |
+
filter_conditions.append(
|
| 980 |
+
f"網路投保機率 ≥ {min_online_conv:.2f} 或 O2O 預約機率 ≥ {min_o2o_conv:.2f}"
|
| 981 |
+
)
|
| 982 |
|
| 983 |
# ✅ 條件摘要顯示
|
| 984 |
st.markdown("#### 您的篩選條件為:")
|