latex2exp is an R package that lets you use LaTeX in plots. It parses and converts LaTeX to R’s custom plotmath expressions. You can read the full documentation on the package’s website. Expressions returned by latex2exp can be used to create formatted text and mathematical formulas and symbols to be rendered as axis labels, annotations, legends, titles, etc. throughout R’s plotting system.