Algorithms for association between genotype and the resulting physical traits while considering evolutionary history