changed prep code to work with full SNP matrix