Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -39,5 +39,6 @@ prediction = model.predict(input_df)
|
|
39 |
st.write(f"The estimated house price range is ${prediction[0]:,.2f}")
|
40 |
explainer = 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')
|
|
|
39 |
st.write(f"The estimated house price range is ${prediction[0]:,.2f}")
|
40 |
explainer = shap.Explainer(model, X_train)
|
41 |
shap_values = explainer(X_test)
|
42 |
+
fig, ax = plt.subplots()
|
43 |
shap.summary_plot(shap_values, X_test, plot_type="bar", show=False)
|
44 |
+
st.pyplot(fig, bbox_inches='tight')
|