set pending to_html to improve algorithm to calculate largest number, add custom palette method and test