Identify segments from a given population after admixture #1887
Replies: 5 comments 7 replies
-
Hi @leovallini, welcome 👋 I haven't run your code or thought too hard about it, but your approach basically seems right to me. I think it'd be helpful if you printed out the migration events that you get here, and a simulated tree ( |
Beta Was this translation helpful? Give feedback.
-
@jeromekelleher below is the list of migrations with
|
Beta Was this translation helpful? Give feedback.
-
with no recombination I guess individuals within the admixed population will migrate (backward in time) entirely (= all of their genome) either to population B (with prob=0.75) or to population C (with prob=0.25). |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
I am now simulating the following: Nodes Table
Migration Table
|
Beta Was this translation helpful? Give feedback.
-
Hi msprime community,
I'm sorry for the noob question but I was not able to find the solution elsewhere:
I have a simple population demography where population D is the admixture of population B and C with proportion 0.75 and 0.25 (see figure).
What I want to do is simulate multiple individuals from the admixed population D and for each of them(crucial, I want to know that for single individuals, not population-wise) save the left and right coordinates of the chunks that come from population C.
So far I only managed to do that for a single individual using record_migrations = True and selecting migration events where the source population is C, when I try to do that for more than one individual in the admixed D population, however, I get many migration events where the node does not coincide with one of my samples nodes; I think the reason for that is that the segments referred to in these migrations are shared by more than one individual in the admixed population, but how do I know which ones?
Below is the code for what I have done so far, which works fine if I simulate 1 individual from population D, but not when there is more than 1.
Thanks for your help,
Leonardo
Beta Was this translation helpful? Give feedback.
All reactions