Renamed functions to follow the function_names_with_underscores style. Fixes RTbug #1903. (calculate_quantiles): Raise ValueError if 'percents' is invalid.