After setting the DUA restriction level, check the setting and restricted data elements.

see_dua_level(show_restrictions = FALSE, sort_vars = TRUE, ...)

Arguments

show_restrictions

Show the names of the variables that are restricted by the current level if TRUE.

sort_vars

Sort variables alphabetically when printing restrictions; if FALSE, prints in the order saved in the crosswalk file

...

For debugging.

Examples

## -------------- ## Setup ## -------------- ## set DUA crosswalk dua_cw <- system.file('extdata', 'dua_cw.csv', package = 'duawranglr') set_dua_cw(dua_cw)
#> -- duawranglr note ------------------------------------------------------------- #> DUA crosswalk has been set!
## -------------- ## set restriction level set_dua_level('level_i') ## show name of current restriction level see_dua_level()
#> -- duawranglr note ------------------------------------------------------------- #> You have set restrictions at [ level_i ].
## ...include names of restricted elements see_dua_level(show_restrictions = TRUE)
#> --------------------------------------------------------------------------------
#> You have set restrictions at [ level_i ]
#> --------------------------------------------------------------------------------
#> #> RESTRICTED VARIABLE NAMES:
#> - dob
#> - gender
#> - raceeth
#> - sid
#> - sname
#> - tid
#> - tname
#> - zip
#>
#> --------------------------------------------------------------------------------
## ...show variable names in order saved in crosswalk file see_dua_level(show_restrictions = TRUE, sort_vars = FALSE)
#> --------------------------------------------------------------------------------
#> You have set restrictions at [ level_i ]
#> --------------------------------------------------------------------------------
#> #> RESTRICTED VARIABLE NAMES:
#> - sid
#> - sname
#> - dob
#> - gender
#> - raceeth
#> - tid
#> - tname
#> - zip
#>
#> --------------------------------------------------------------------------------