dataset_zap_data_dict {madshapR}R Documentation

Remove labels (attributes) from a data frame, leaving its unlabelled columns

Description

Removes any attributes attached to a data frame. Any value in columns will be preserved. Any 'Date' (typeof) column will be recast as character to preserve information.

Usage

dataset_zap_data_dict(dataset)

Arguments

dataset

A dataset object.

Details

A dataset is a data table containing variables. A dataset object is a data frame and can be associated with a data dictionary. If no data dictionary is provided with a dataset, a minimum workable data dictionary will be generated as needed within relevant functions. Identifier variable(s) for indexing can be specified by the user. The id values must be non-missing and will be used in functions that require it. If no identifier variable is specified, indexing is handled automatically by the function.

Value

A data frame identifying a dataset.

See Also

haven::zap_labels().

Examples

{

# use madshapR_DEMO provided by the package

dataset <- madshapR_DEMO$dataset_TOKYO
data_dict <- as_data_dict_mlstr(madshapR_DEMO$data_dict_TOKYO)
dataset <- data_dict_apply(dataset,data_dict)
head(dataset_zap_data_dict(dataset))

}


[Package madshapR version 1.1.0 Index]