Skip to content

Update the variable dictionary to add human-readable transformations for values #28

Description

@jeancochrane

We apply some transformations to model features in https://github.com/ccao-data/pinval in order to make the values more readable, e.g. formatting other_tax_bill_rate as a percentage and formatting acs5_median_income as currency. It would be nice to encode these transformations in vars_dict so that we can use them more widely.

See Dan's original comment (ccao-data/homeval#18 (comment)) for more context.

Data dictionary update checklist

  • Make your updates to the source data file and commit them in a branch.
  • Run data-raw/<data_dict>.R. This will save the CSV as an R data file (data/<data_dict>.Rda). This file is what the unit tests and package run against.
  • Update the docstring for the data dict in R/data.R. This is where help docs for the packaged data.frame are kept. It needs to be updated manually to reflect the changes to the raw data.
  • Run devtools::test() to make sure all unit tests pass with the new dictionary.
  • Run devtools::document() to generate new man files from the changes to R/data.R.
  • Run devtools::check() to run a test package build.
  • Run pkgdown::build_site() and navigate to the reference page to make sure the changes are reflected on the docs website.
  • Commit changes made by the preceding commands, push them to GitHub, and request a review.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions