pii_table: Creates a summary table of PII for a dataset.

Description Usage Arguments Examples

View source: R/pii_table.R

Description

This function takes a dataframe and searches each column for presence of any text that appears as PII: emails, DOB, SSNs, and phone numbers.

Usage

1
pii_table(df, path, writeout)

Arguments

df

A dataframe with (vector-able) variables.

path

destination for tables to be written out

writeout

TRUE/FALSE indicator of whether or not full detailed results to be written out. An individual table will be written out for each column, with PII results for every row of the table.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
set.seed(2)
testcase <- data.frame(name = generator::r_full_names(2),  
snn = generator::r_national_identification_numbers(2), 
dob = generator::r_date_of_births(2), 
email = generator::r_email_addresses(2), 
phone = generator::r_phone_numbers(2),  
credit_card = generator::r_credit_card_numbers(2), 
lat = generator::r_latitudes(2), 
lon = generator::r_longitudes(2), 
stringsAsFactors = FALSE)

pii_table(testcase, writeout = FALSE)

DevikaNair90/prybar documentation built on May 11, 2020, 2:47 a.m.