Description Usage Arguments Examples
Create a gender indicator or dummy from a character vector.
1 2 | code_gender(column, female_id = "default", female_value = 1, na_id = "NA",
return_class = "numeric")
|
column |
A column from a survey data frame where gender is recorded. |
female_id |
A regex identifier for the female values. If omitted,
the default value is |
female_value |
What should be the returned value for females (Default: |
na_id |
Is there a special character ID for missing variables? (Default: |
return_class |
Default is |
1 2 3 4 | code_gender(column = as.character (c("1-no", "1-nő",
"NA", NA, "0")),
female_id = "1", female_value = 1,
na_id = "NA")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.