SimHap: A comprehensive modelling framework and a simulation-based approach to haplotypic analysis of population-based data