count_vars | R Documentation |
Count then number of columns matching var_pattern
that have value var_val
.
count_vars( df, var_pattern, var_val = 1, attrib_name, attrib_vars = var_pattern )
df |
Data frame. Household-level microdata that contains the variables to count. |
var_pattern |
Character Regular expression used to select variables to be counted. |
var_val |
Numeric. Value(s) to count in columns identified by |
attrib_name |
Character. Name of attribute. |
attrib_vars |
Character. Regular expression that identifies the variable(s) in |
Data frame of attributes with the following columns:
interview__id
interview__key
attrib_name
attrib_val
attrib_vars
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.