The UNIX sort command was not correct. I fixed it so that the numerical sort was only applied to the second column.