crimeutils (version 0.1.0)

make_latex_tables: Creates a .tex file with LaTeX code to create a table from an R data.frame.

Description

Creates a .tex file with LaTeX code to create a table from an R data.frame.

Usage

make_latex_tables(
  data,
  file,
  caption = "",
  label = "",
  multi_column = NULL,
  footnote = "",
  sideways = FALSE
)

Arguments

data

A data.frame or a list of data.frames. If a data.frame, the table is created with the values in that data.frame. If a list of data.frames, the table gets one panel for each data.frame. If the list is named, will use the names to create panel labels.

file

A string with the name of the file to save the .tex as.

caption

(Optional) A string with the caption for the table (i.e. the table title).

label

(Optional) A string with the reference for the table - to be used when referencing the table in the text. If NULL,

multi_column

(Optional) A named vector with the names being the names of the multi-column and the values being the width of the multi-column.

footnote

(Optional) A string with text for the footnote of the table.

sideways

(Optional) If TRUE, will make a sideways table (useful for large tables), otherwise (default) will make a normal table.

Value

Nothing. It will create a .tex file in the current working directory.