corrected minor error in determining color scale