title: save ipython html object as pdf
body: <p>I'm plotting some data using <code>shap</code>, which returns me (in console) a 
  <code>&lt;IPython.core.display.HTML object&gt;</code>. I would like to convert the object to a PDF and save it. </p>
  
  <p>I do understand that there is some hassle, as I probably would need to simulate a browser to open and view the HTML in. </p>
  
  <p>What would be the most straight-forward way of storing the html output as PDF?</p>
  
  <p>Please note that I am not inside a browser/iPython notebook, and I do not want to create and convert a whole iPython notebook.</p>