Use this function to turn an stable object in to a high-quality pdf file,
The result can be included in an Rmarkdown file rendered to .html or
other uses.
an stable object; this can be the result of calling stable() or
stable_long().
arguments passed to st_aspdf(); please take the time to review
the details in that help topic.
the relative width of the image; passed to st_image_show();
this must be greater than 0 and less than or equal to 1.
passed as an option to standalone latex output type; see
details.
A possibly resized magick image object (see magick::image_read_pdf()).
This function depends on the magick and pdftools packages being installed.
First, x is rendered with st_aspdf()
Next, the pdf file is read using magick::image_read_pdf()
Finally, the image is possibly resized via st_image_show()