Dhanushlevi commited on
Commit
6b876eb
·
1 Parent(s): 1727857

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -87,6 +87,8 @@ st.write(user_data_df)
87
 
88
  if st.button('Predict'):
89
  prediction = model.predict(user_data_df)
90
- st.markdown('<div class="prediction">Placement Prediction: <span style="color: green;">Placed</span>' if prediction[0] == 1 else '<div class="prediction">Placement Prediction: <span style="color: red;">Not Placed</span>', unsafe_allow_html=True)
 
 
91
 
92
  st.markdown('</div>', unsafe_allow_html=True)
 
87
 
88
  if st.button('Predict'):
89
  prediction = model.predict(user_data_df)
90
+ placement = "Placed" if prediction[0] == 1 else "Not Placed"
91
+ prediction_text = f"Placement Prediction: <span style='color: green;'>{placement}</span>" if placement == "Placed" else f"Placement Prediction: <span style='color: red;'>{placement}</span>"
92
+ st.markdown(f"<div class='prediction'>{prediction_text}</div>", unsafe_allow_html=True)
93
 
94
  st.markdown('</div>', unsafe_allow_html=True)