25 using locus_ID_type = std::string;
29 DiploidIndividual(std::pair<allele_type, allele_type>
const &locus, locus_ID_type
const &name)
34 DiploidIndividual(locus_ID_type
const &name, std::pair<allele_type, allele_type>
const &locus)
40 m_loci[name] = std::make_pair(allele_1, allele_2);
44 m_loci[name] = std::make_pair(allele_1, allele_2);
49 m_loci[name] = std::make_pair(a1, a2);
65 unsigned int nGenotypedLoci()
const
70 std::pair<allele_type, allele_type>
const &alleles(locus_ID_type
const &locus)
const
72 return m_loci.at(locus);
75 std::set<locus_ID_type> loci()
const
77 std::set<locus_ID_type> loci;
78 for (
auto const &it : m_loci)
80 loci.insert(it.first);
86 std::map<locus_ID_type, std::pair<allele_type, allele_type>> m_loci;