subjectDistributionTableToLatex: Convert Subject Distribution Table To LaTeX

Description Usage Arguments Value Author(s) Examples

Description

Converts a subject distribution table created using subjectDistributionTable() into text which can be used in the typesetting language LaTeX. The table created can have its caption and label specified using the respective function arguments. The decimal point rounding can be specified by the function argument roundDP.

Usage

1
2
3
subjectDistributionTableToLatex(subjectDistributionTable,
  caption = "Placeholder Caption", label = "table:SubjectDistributionTable",
  roundDP = 1)

Arguments

subjectDistributionTable

The subject distribution table created using subjectDistributionTable()

caption

The caption to give the table in LaTeX

label

The label to give the table in LaTeX

roundDP

The number of decimal places to round the numbers to on the table

Value

The LaTeX code representing the subject distribution table

Author(s)

Alexander Luke Spedding, alexspedding271@gmail.com

Examples

1
2
3
4
5
6
7
8
all <- generaterandomsubjects(1000)
all$Age <- stats::runif(1000,50,80)
all <- addrandomgender(all)
all <- addrandomdiagnosis(all)
sdt <- subjectDistributionTable(all, "Diagnosis")
subjectDistributionTableToLatex(subjectDistributionTable = sdt,
                                caption="Subject Distribution Table",
                                label="table:SDT", roundDP=1)

AlexDiru/rsurfer documentation built on May 8, 2019, 8:45 a.m.