replace_confidential.RdThe NZ census commonly uses the notation of '..C' when values are below a certain threshold that they may reveal private details of certain individuals. However, it is often required in an analysis to replace these values and convert the column to an integer (to include ..C they need to be character).
replace_confidential(.data, replacement_value = NA_integer_)
| .data | The data set to have its confidential values removed. |
|---|---|
| replacement_value | The value to replace the confidential ones with. Defaults to NA_integer. |
This function takes the data set, and a replacement value and replaces all of the ..C values. Mainly for use within the transform_census function.