View source: R/R04-Data_wrangling.R
camr_values_labels | R Documentation |
A function that takes two columns in a data frame (assumed to be an initial column of values and a subsequent column of associated labels) and displays the assignment of values to labels.
camr_values_labels(dtf, values, labels)
dtf |
A data frame. |
values |
A character string, the column name for the values of interest (non-standard evaluation possible). |
labels |
A character string, the column name for the labels of interest (non-standard evaluation possible). |
A data frame with a column for values and a column for associated labels.
Kevin Potter
data( example_CAM_data_set )
example_CAM_data_set$SBJ.CHR.Biological_sex <-
c( "Male", "Female" )[ example_CAM_data_set$SBJ.INT.Biological_sex ]
example_CAM_data_set |>
camr_values_labels( SBJ.INT.Biological_sex, SBJ.CHR.Biological_sex )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.