codebook {volker} | R Documentation |
Get variable labels from their comment attributes
Description
Usage
codebook(data, cols)
Arguments
data |
A tibble. |
cols |
A tidy variable selections to filter specific columns. |
Value
A tibble with the columns: - item_name: The column name. - item_group: First part of the column name, up to an underscore. - item_class: The last class value of an item (e.g. numeric, factor). - item_label: The comment attribute of the column. - value_name: In case a column has numeric attributes, the attribute names - value_label: In case a column has numeric attributes or T/F-attributes, the attribute values. In case a column has a levels attribute, the levels.
Examples
volker::codebook(volker::chatgpt)
[Package volker version 2.0.1 Index]