algorithm to guess correct data type for each field in a text file