Partition continuous data into discrete groups intelligently
It is often desirable to divide continuous data into multiple discrete classes to explore certain hypotheses and leverage certain methods that can't be applied directly to continuous data. This is often done relatively arbitrarily.
A simple version of the method would break the data into a user-determined number of groups. A more sophisticated approach would attempt to estimate the number of clusters. By using model-based approaches, this could be done in a maximum-likelihood or Bayesian manner.
Dividing data into K partitions by maximum likelihood is now implemented. Also implemented a bootstrap function for the partitioning.
This should generate a distribution of possible assignments weighted by likelihood, to average over the uncertainty in the assignment.