Code required for analyses described in Genome-wide local ancestry and the functional consequences of admixture in African and European cattle populations (doi: 10.1101/2024.06.20.599852) and Chapter 2 of Integrative population and functional genomics of African cattle (PhD thesis).