anonymous | R Documentation |
Anonymizing a data frame by avoiding vulnerability to a rainbow table attack.
anonymous(data, ID, string_length = 15, SEED = NULL)
data |
data.frame. A dataset with the a variable to change its values. |
ID |
character. A string with the variable name to change its values. |
string_length |
numeric. It defines the string length of the new identification variable. |
SEED |
to be passed to |
anonymous
function returns a list with two data frames:
data |
original data with the new variable |
dictionary |
data frame with the original variable and the new one |
Cesar Gamboa-Sanabria
anonymouspopstudy
library(dplyr)
df <- select(mutate(mtcars, id=rownames(mtcars)), id, !contains("id"))
anonymous(df, ID="id", string_length = 5, SEED=160589)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.