A population-level strain genotyping method to study pathogen strain dynamics in human infections