A function for reading LaTeX files

Description

A function for reading LaTeX files

Usage

1
read.latex(file, filepath)

Arguments

file

is the name of a file with .tex extension. The .tex file must be generated by R Sweave using package 'knitr'.

filepath

is the absolute filepath where .tex file is located.

Value

read.latex returns two character strings: tex and path, both of which are used by write.rtf.

See Also

write.rtf

Examples

1
2
3
4
5
6
7
8
#Read a sample LaTeX file
file<-'connect3-minimal.tex'
filepath<-paste(sub("examples/.*","\\1",
          system.file("examples","connect3-minimal.tex",package="connect3")),
          "examples", sep='')
obj<-read.latex(file, filepath)
obj$tex
obj$path

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.