Determines the modality of the dataset
modes.RdThis function tests the dataset's modality. It uses the modetest function from the multimode package written by Ameijeiras-Alonso et al. (2019) to determine the excess mass test statistic and test the number of modes. As a matter of course, this function runs the cleanData function, negating the need to run it separately.
Examples
modetest <- modes(cutoffvalue:::exampledata)
#> Warning: A modification of the data was made in order to compute the excess mass or the dip statistic
#> Warning: A modification of the data was made in order to compute the excess mass or the dip statistic
#> Modality Test Results:
#> - Excess mass = 0.097447
#> - p-value = 0.006
#> **Reject null hypothesis** Distribution contains more than one mode; proceed with analyses.
#>
#> Test Credit: Ameijeiras-Alonso et al. (2019) excess mass test
#>