added a reduction function for getting the column class right