create_tables: Create Frequency Tables

Description Usage Arguments Value

View source: R/create_tables.R

Description

Create tables of row/column sums, with percentages suitable for output addresses rounding and formatting, prepares tables for output to MS Word file options to include total values as well

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
create_tables(
  freq.table,
  percent.table = NULL,
  decimal1 = 0,
  decimal2 = 1,
  row.names.provided = NULL,
  col.names.provided = NULL,
  prop.table.margin = NULL,
  prop.table.N = NULL,
  add.margins = F,
  add.N.to.colnames = F,
  add.col.of.rownames = F,
  name.of.rownames = NULL
)

Arguments

freq.table

pass the frequency table to the function. Must be a matrix or a dataframe.

percent.table

pass the table of percentages; default is to compute this in the function

decimal1

number of decimals in sum

decimal2

number of decimals in percentage

row.names.provided

pass a character vector of the row names for the output table

col.names.provided

pass a character vecotr of the column nanmes for the output table

Value

Returns a dataframe of character values


CJangelo/R2Word documentation built on June 26, 2021, 6:35 a.m.