BMC BioinformaticsGeneticsPeer-reviewed journal article
PyMSQ: a python package for fast Mendelian sampling (co)variance and haplotype-based similarity in genomic selection
Abstract
BackgroundWhile genomic selection (GS) boosts rapid genetic gains by leveraging dense marker data for genomic estimated breeding values (GEBVs), prolonged application can reduce haplotype diversity and increase inbreeding. To address these risks, recent research has emphasized Mendelian sampling variance (MSV) and covariance (MSC), which capture within-family (co)variation not fully reflected in GEBVs. In parallel, theoretical advances have introduced a haplotype-based similarity measure that targets shared heterozygous segments, enabling more direct control over haplotype diversity--either standalone or in combination with conventional coancestry-based and genomic relationship matrices. ResultsWe present PyMSQ, an open-source Python package that implements two key developments: (1) a matrix-based approach for computing MSV and MSC in single-trait, multi-trait, and zygotic contexts, and (2) a haplotype-based similarity metric. By combining this matrix-based framework with optimized scientific libraries, PyMSQ achieves up to 332-fold faster computations than gamevar--a publicly available alternative--while preserving numerical accuracy. Using a Holstein-Friesian dataset, we demonstrate PyMSQs effectiveness in deriving MSV and MSC, as well as its novel similarity measure, which complements standard genomic relationship matrices by explicitly quantifying shared heterozygous segments rather than overall allele sharing, thereby providing additional insights for balancing immediate gains with long-term diversity. ConclusionBy facilitating the practical use of MSV, MSC, and a haplotype-based similarity metric, PyMSQ enables breeders and quantitative geneticists to adopt haplotype diversity constraints--whether as a standalone criterion or in synergy with optimal contribution selection. This framework opens new possibilities for preserving key haplotypic segments, ultimately supporting more sustainable genomic selection strategies. PyMSQ is freely available under an MIT License at https://github.com/aromemusa/PyMSQ.
- assay: whole-genome sequencing
- research focus: variant calling
- research focus: genome assembly
- research focus: software / tool
- research focus: benchmarking
- approach: statistical model
- approach: matrix factorization
- Citations
- 0
Reproducibility ledger
Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.
Sign in to file a reproducibility report.
Related papers
- A similarity matrix for preserving haplotype diversity among parents in genomic selection
Abdulraheem Arome Musa, Norbert Reinsch·Journal of Animal Breeding and GeneticsPeer-reviewed·Mar 4, 2025
- MateR: a novel framework for computing the usefulness criterion and applying genomic mating
Javier Fernández-Gónzalez, Saif M. Khodary, Julio Isidro y Sánchez·GeneticsPeer-reviewed·Jan 19, 2026
- Evolutionary computing to assemble standing genetic diversity and achieve long-term genetic gain
Kira Villiers, Kai P. Voss‐Fels, … Ben J. Hayes·The Plant GenomePeer-reviewed·May 30, 2024
- Comparison of localGEBV and Optimal Haplotype Stacking Fitness Functions using a Novel R Package: HapSelect
Will Shaffer, Victor Papin, … Eric G. Dinglasan·bioRxiv·Jul 13, 2026
- Mate selection: a useful approach to maximize genetic gain and control inbreeding in genomic and conventional oil palm (Elaeis guineensis Jacq.) hybrid breeding
Billy Tchounke, Leopoldo Sánchez, … David Cros·bioRxiv·Jun 10, 2022
- Advanced marker-assisted selection versus genomic selection in breeding programs
Бернд Деген, Niels A. Müller·bioRxiv·Feb 20, 2023