View source: R/valid_ssn_add_col.R
valid_ssn_add_col | R Documentation |
Add a valid_ssn column to a data.frame or data.table.
valid_ssn_add_col(df, ssn_field)
df |
data.frame or data.table with an ssn column. |
ssn_field |
Name of the ssn column/field. |
ssn_df <- data.frame(ssn = c("123-45-6789", "368-96-8955", "999998888", "287-65-4321")) ssn_df <- valid_ssn_add_col(ssn_df, "ssn") ssn_df ssn ssn_valid 1 123-45-6789 FALSE 2 367-94-8940 TRUE 3 999998888 FALSE 4 287-65-4321 TRUE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.