Skip to contents

This adapts code from R base summary.factor. It adds the calculation of entropy as a measure of diversity. This was a method summary_factor, but R check kept objecting, no matter what I tried

Usage

summary_factor(y)

Arguments

y

a factor (non-numeric variable)

Value

A list, including the summary table and vector of summary stats if requested.

Author

Paul E. Johnson [email protected]