Learn R Programming

datapackage (version 0.2.1)

dp_categorieslist: Get the a data.frame with the categories for a variable.

Description

Get the a data.frame with the categories for a variable.

Usage

dp_categorieslist(x, ...)

# S3 method for default dp_categorieslist( x, fielddescriptor = attr(x, "fielddescriptor"), datapackage = dp_get_datapackage(fielddescriptor), ... )

# S3 method for fielddescriptor dp_categorieslist( x, datapackage = dp_get_datapackage(x), normalised = FALSE, ... )

Value

Returns a data.frame with the categories or NULL when none could be found.

Arguments

x

the variable for which to get the Categories List

...

used to pass extra arguments on to other methods.

fielddescriptor

the Field Descriptor associated with the variable.

datapackage

the Data Package where the variable is from.

normalised

if TRUE the column with values will be named value and the the columnd with labels label.