Added calculation of color distribution