I am looking to display SHAP plots, here is the code:import xgboost import shap
shap.initjs() # load JS visualization code to notebookX,y = shap.datasets.boston() # train XGBoost model
model = xgboost.train({"learning_rate": 0.01}, xgboost.DMatri...
As @Vinh dqvinh87​ noted, the accepted solution only works for force_plot. For other plots, the following trick works for me:import matplotlib.pyplot as plt
p = shap.summary_plot(shap_values, test_df, show=False)
display(p)
I am trying to display the html output or read in an html file to display in databricks notebook from pandas-profiling.import pandas as pd import pandas_profiling df = pd.read_csv("/dbfs/FileStore/tables/my_data.csv", header='infer', parse_dates=Tru...
I'm trying to display() the results from calling first() on a DataFrame, but display() doesn't work with pyspark.sql.Row objects. How can I display this result?