great-tables
great-tables copied to clipboard
nbconvert's PDF cannot include the table: Add Save as Image
Currently a table cannot be correctly imported into a PDF made by nbconvert:
is rendered in PDF like this:
Adding Save as Image would allow a great-table to be included in every kind of document.
Currently we use a ._repr_html_() method to produce HTML for jupyter. I wonder if one of these other methods would enable us to give nice outputs in nbconvert PDFs?
https://ipython.readthedocs.io/en/stable/config/integrating.html#custom-methods
Are you using the WebPDFExporter or the PDFExporter? I wonder if the WebPDFExporter would work?
(To render to the PDFExporter, I think we'd need to implement _repr_latex_(), which I think will happen eventually, and is worth tracking!)
+1. I would find this very useful. Specifically, it would be great to have something like https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.savefig.html for GT so that I can manually export a table as a png, for example.
One of the problems with R's gtsave is that it relies on web-tools to generate an image file of the table. This can be really annoying for pipelines running on containers/VMs because it adds a heavy dependency.
Hopefully we can avoid that with this package.