codebook_items: Tabular codebook

Description Usage Arguments Examples

View source: R/codebook.R

Description

Renders a tabular codebook including attributes and data summaries. The table is generated using DT::datatable() and can be exported to CSV, Excel, etc.

Usage

1
codebook_items(results, indent = "##")

Arguments

results

a data frame, ideally with attributes set on variables

indent

add # to this to make the headings in the components lower-level. defaults to beginning at h2

Examples

1
2
3
4
5
6
data("bfi")
## Not run: 
# doesn't show interactively, because a html widget needs to be registered
codebook_items(bfi)

## End(Not run)

Example output

dev.new(): using pdf(file="Rplots1.pdf")
No viewer found, probably documenting or testing



### Codebook table

## PhantomJS not found. You can install it with webshot::install_phantomjs(). If it is installed, please make sure the phantomjs executable can be found via the PATH variable.
## Warning in normalizePath(f2): path[1]="webshot10ed882ee05a82.pdf": No such file
## or directory
## Warning in file(con, "rb"): cannot open file 'webshot10ed882ee05a82.pdf': No
## such file or directory
## Error in file(con, "rb"): cannot open the connection

codebook documentation built on July 1, 2020, 10:28 p.m.