MyNixOS website logo
Description

Compile and Preview Snippets of 'LaTeX'.

Compile snippets of 'LaTeX' directly into images from the R console to view in the 'RStudio' viewer pane, Shiny apps and 'RMarkdown' documents.

CRAN_Status_Badge Project Status: Active - The project has reached a stable, usable state and is being actively developed. Coverage Status Covrpage Summary R-win buildstatus R-mac buildstatus R-linux buildstatus

texPreview

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.

Functionality

  • 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:

    • Must have pdflatex in PATH, Windows users can install by running installr::install.MikTeX
    • TeX libraries that are used: 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().

    • Ghostscript: If you are installing TeX with tinytex make sure to install ghostscript onto your system.

Examples

Basic

Pan/Zoom.

Metadata

Version

2.1.0

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows