dvj4 commited on
Commit
edfa47a
·
1 Parent(s): 1cf5d5c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -37,8 +37,7 @@ input_df = pd.DataFrame({
37
  })
38
  prediction = model.predict(input_df)
39
  st.write(f"The estimated house price range is ${prediction[0]:,.2f}")
40
- explainer = shap.Explainer(model)
41
  shap_values = explainer(X_test)
42
- shap.summary_plot(shap_values, X_test)
43
-
44
- shap_interaction_values = explainer.interaction_plot(X_test)
 
37
  })
38
  prediction = model.predict(input_df)
39
  st.write(f"The estimated house price range is ${prediction[0]:,.2f}")
40
+ eexplainer = shap.Explainer(model, X_train)
41
  shap_values = explainer(X_test)
42
+ shap.summary_plot(shap_values, X_test, plot_type="bar", show=False)
43
+ st.pyplot(bbox_inches='tight')