-
Notifications
You must be signed in to change notification settings - Fork 0
/
Readme.Rmd
57 lines (41 loc) · 4.13 KB
/
Readme.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
---
title: "How-To"
author: Maël-Luc Buron, Peter-Paul de Wolf, Bernhard Meindl, Tobias Enderle
date: "`r Sys.Date()`"
output:
md_document:
variant: markdown_github
pdf_document:
toc: false
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, eval = FALSE, echo = FALSE}
# R commands to produce the required md-output that is shown on github
rmarkdown::render("Readme.Rmd", output_format = "md_document", output_file = "README.md")
```
```{r, echo = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "README-"
)
```
# CensusProtection
## How to use the open-source versions of the recommended census protection methods
This repository explains how to use tools and methods recommended for census 2021 protection. Part 1 is related to targeted record swapping while part 2 focuses on the cell-key method. The methods can be used independently: it is either possible to compute unperturbed hypercubes with swapped microdata (part 2 can be ignored), perturbed hypercubes with original microdata (part 1 can be skipped), or perturbed hypercubes with swapped microdata (part 1 then part 2).
The instructions below contain references to the respective Github-repositories with the updated versions of the tools recommended for the protection of census. The activities related with development of tools and methods for the census protection were co-funded by Eurostat.
### Part 1: Targeted record swapping
To apply record swapping to original microdata it is possible to use either the `R` package [`recordSwapping`](https://github.com/sdcTools/recordSwapping) (paragraph 1.1) or [`MuARGUS`](https://github.com/sdcTools/muargus) (paragraph 1.2).
Both implementation use the same underlying new C++ code which is optimized to be incredibly fast. This new implementation of the targeted record swapping method is intended to be very close to the SAS codes tested in the previous SGA based on the ONS codes. More information regarding the small differences can be found in the vignette of the [`recordSwapping`](https://github.com/sdcTools/recordSwapping) package.
#### 1.1 R-package recordSwapping
The package is developed at [`github.com/sdcTools/recordSwapping`](https://github.com/sdcTools/recordSwapping) where also installation instructions and example usage as well as an introductory vignette can be found.
#### 1.2 MuARGUS
The latest release of [`MuARGUS`](https://github.com/sdcTools/muargus) that includes the implementation of record swapping is available at [`github.com/sdcTools/muargus/releases`](https://github.com/sdcTools/muargus/releases) where also a quick reference documentation with explanations and screenshots can be downloaded.
### Part 2: Cell-key method
The cell-key method can be applied either with the R package [`cellKey`](https://github.com/sdcTools/cellKey) (paragraph 2.2) or [`tauArgus`](https://github.com/sdcTools/tauargus) (paragraph 2.3). Both implementation use the [`ptable`](https://github.com/sdcTools/ptable) package (paragraph 2.1).
#### 2.1 R-package ptable
The package is developed at [`github.com/sdcTools/ptable`](https://github.com/sdcTools/ptable) where also installation instructions and example usage can be found. The package includes a vignette and a graphical user interface and it can draw plots that describe the perturbations that will be applied to the hypercubes based on a specific pTable with the [`cellKey`](https://github.com/sdcTools/cellKey) package, [`tauArgus`](https://github.com/sdcTools/tauargus) or SAS macros.
#### 2.2 R-package cellKey
The package is developed at [`github.com/sdcTools/cellKey`](https://github.com/sdcTools/cellKey) where also installation instructions and example usage can be found. The package includes also a detailed vignette that helps users getting started with the functionality of the package.
#### 2.3 TauARGUS
The latest release of [`TauArgus`](https://github.com/sdcTools/tauargus) that includes the implementation of the cellKey method is available at [`github.com/sdcTools/tauargus/releases`](https://github.com/sdcTools/tauargus/releases) where also a quick reference documentation with explanations and screenshots can be downloaded.