View source: R/R06-Inventories_scales_questionnaires.R
camr_add_inventory_item | R Documentation |
Convenience function to add a column with scores for an individual item or question from an inventory, survey, or questionnaire. Can also add the associated codebook entry for the item.
camr_add_inventory_item(
dtf_original,
dtf_new,
chr_original_column,
chr_new_column,
vec_response_options = NULL,
vec_new_values = NULL,
lst_values_and_labels = "",
chr_inventory = "",
chr_question = "",
chr_description = "",
...
)
dtf_original |
A data frame with the column of scores for the given item or question. |
dtf_new |
A data frame to which the column of scores will be added. |
chr_original_column |
A character string, the
column name in |
chr_new_column |
A character string, the
new column name to use in |
vec_response_options |
A vector, the original response options. Used to recode the response options if needed. |
vec_new_values |
A vector, the new values to
replace |
lst_values_and_labels |
A named list with
|
chr_inventory |
A character string, the name of the inventory, survey, or questionnaire to which the item belongs. |
chr_question |
A character string, the item's framing question. |
chr_description |
A character string,
allows a user to specify a custom description
rather than one auto-filled using |
... |
Additional arguments for the camr_add_codebook_entry function. |
A data frame with an additional column containing the scores for the individual item or question.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.