Refactored out a function for seeing if a dataset has multiple classes