Rename and Encode Data Frames Using External Crosswalk Files

A pair of functions for renaming and encoding data frames using external crosswalk files. It is especially useful when constructing master data sets from multiple smaller data sets that do not name or encode variables consistently across files. Based on similar commands in 'Stata'.


crosswalkr 0.2.2

  • encoded vector now output in same class as clean values from crosswalk file; this means that if the raw variable is a character (like state name) and the clean encoding value is an integer (like FIPS code), then the new labelled vector will be an integer class. This is the logical behavior and should work better with transfer to Stata, which only takes labels on numeric classes.
  • new tests

crosswalkr 0.2.1

  • adjustments to account for new haven labelled classes
  • various improvements and bug fixes

crosswalkr 0.1.2

  • update documentation
  • update vignette

crosswalkr 0.1.1

  • Initial CRAN release

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


0.2.6 by Benjamin Skinner, a year ago

Report a bug at

Browse source code at

Authors: Benjamin Skinner [aut, cre]

Documentation:   PDF Manual  

MIT + file LICENSE license

Imports haven, labelled, methods, readr, readxl, tibble

Suggests testthat, knitr, rmarkdown, dplyr

See at CRAN