Efficiently iterate, refine and share snippets of LaTeX in R with ease.
texPreview
compiles LaTeX directly into images from the
R console to view in the RStudio viewer pane, Shiny apps and RMarkdown
documents.
Supports: character, knitr, kableExtra, xtable, texreg, equatiomatic classes
Extendable: S3
methods can be
written for the main call, texPreview::tex_preview
, to use
with new classes for rendering and printing.
Rstudio Addin: Users can highlight text in the editor and invoke preview automatically.
RMarkdown document compatible with all document outputs
Shiny compatible via
shiny::renderImage
or as part of htmlwidgets like
slickR::slickR
.
Pan and Zoom functionality: When the output is
set to ‘svg’ the default output to the viewer is
svgPanZoom::svgPanZoom
, which allows for panning and
zooming on the image in the viewer. If the package is not installed a
static image will be loaded.
System Requirements:
standalone
,
xcolor
, booktabs
, multirow
,
array
, helvet
, amsmath
,
rotating
, listings
, graphicx
,
setspace
, caption
Using tinytex you can run
install.packages('tinytex')
tinytex::tlmgr_install(c('standalone', 'xcolor', 'booktabs', 'multirow', 'amsmath',
'listings', 'setspace', 'caption', 'graphics', 'tools', 'psnfss', 'varwidth',
'colortbl', 'epstopdf-pkg', 'pgf','makeindex'))
To Check if the system is in compliance with these libraries run
texPreview::check_requirements()
.