Calculate the bimodality coefficient for a numeric vector as specified in Pfister et al. (2013).
bimodality_coefficient(x, na.rm = FALSE)
a numeric vector.
logical specifying whether missing values should be removed.
A numeric value.
The calculation of the bimodality coefficient involves calculating the
skewness and kurtosis of the distribution first. For this, the
skew and kurtosi functions of the
package are used.
Note that type is set to "2" for these functions in accordance with
Pfister et al. (2013).
Pfister, R., Schwarz, K. A., Janczyk, M., Dale, R., & Freeman, J. B. (2013). Good things peak in pairs: A note on the bimodality coefficient. Frontiers in Psychology, 4, 700. http://dx.doi.org/10.3389/fpsyg.2013.00700
mt_check_bimodality for assessing bimodality using several methods in a mousetrap data object.