handling singular matrix exception in cross validation, defining basic use cases for documentation