cmp_types | R Documentation |
Compare the types of variables in a list of dataframes
cmp_types(l)
l |
A list of dataframes. |
A dataframe comparing the types type1
, type2
, ... for
all variables var
in the dataframes in l
. The logical column
type_diff
indicates, if there are differences.
df <- data.frame(fbnr = 1:10, sex = c(2, 1, 2, 1, 1, 2, 2, 1, 2, 1), age = c("24", "23", "23", "41", "23", "39", "30", "18", "31", "48")) df2 <- df %>% dplyr::mutate(new_var = 1, age = as.numeric(age)) %>% dplyr::select(-sex) cmp_types(list(df, df2))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.