cross_count {baizer} | R Documentation |
count two columns as a cross-tabulation table
Description
count two columns as a cross-tabulation table
Usage
cross_count(df, row, col, method = "n", digits = 2)
Arguments
df |
tibble |
row |
the column as rownames in the output |
col |
the column as colnames in the output |
method |
one of |
digits |
the digits of ratios |
Value
data.frame
Examples
cross_count(mini_diamond, cut, clarity)
# show the ratio in the row
cross_count(mini_diamond, cut, clarity, method = "rowr")
# show the ratio in the col
cross_count(mini_diamond, cut, clarity, method = "colr")
[Package baizer version 0.8.0 Index]