def reduce_breed_list(test):
    """
    Input: cleaned dataset
    returns: a data set with the variable "breeds" reduced for cats and dogs. 
    
    Removes the "Mix" part of the breed name and stripped white space.
    Made choice that Domestic Shorthair is equivalent to Domestic Shorthair Mix when it comes to cats
    """
    
    # Fix cat breeds
    test.loc[(test['species']=="Cat")& (test.breed.str.contains('Mix')), 'breed'] = test.breed.str.replace("Mix", "")
    test.loc[(test['species']=="Cat"), 'breed'] = test.breed.str.strip()

    # Fix dog breeds
    test.loc[(test['species']=="Dog")& (test.breed.str.contains('Mix')), 'breed'] = test.breed.str.replace("Mix", "")
    test.loc[(test['species']=="Dog"), 'breed'] = test.breed.str.strip()
    
    return test