The `ns_add_labels` function applies labels to variables in a dataset based on a provided codebook. It assigns variable labels, value labels, and metadata required for the "ns-data" class.
Value
A data frame with the same structure as `data`, but with variable and value labels applied. The resulting object is assigned the class `"ns-data"`.
Examples
data <- ns_get_data(123823)
cb <- ns_get_codebook(123823)
labeled_data <- ns_add_labels(data, cb)