Lesson 17

A

Locked — confirm your name above to begin.

Below are 2 populations. They are the same species. One is colored orange, one is colored blue, not because the individuals are orange and blue. They could be exactly the same. It's just to represent the 2 different populations. You're going to be given 2 sliders: one that controls the migration rate, how often individuals move from one population to the other, and how many crossovers happen per recombination, how frequently you recombine. When you hit Go, you will see the outcome of this. Your job will be to set the migration and crossover rates such that you get a consistent amount of mixing between the 2 populations, seen visibly by the difference in color in the 2 populations. You can see this in the drop-down plot, where you can plot the share of loci that have migrated, introgressed, and the fragments that are cohesive, that have introgressed, in the average fragment length.

The important thing to keep in mind is what we talked about at the end of mutation, which is that while you as an individual have 4 grandparents, each individual locus in you has one parent, and one grandparent, and one great-grandparent. While you as an organism may have many ancestors, as you go back in time, each locus has a single ancestor. Each copy of each locus has a single ancestor stretching back. One way to think about inbreeding is to what extent the ancestral pattern of your loci is disconnected from your individual pedigree. The more consistent they are, the more inbred you are. Migration is the opposite of this, and so you will see in these 2 populations the amount that have ancestry within that population, the amount that match its appropriate color, and the amount of ancestry from outside that population, the number of loci that match the other, different population.

Pair 1Two populations of 25 hermaphrodite genomes, side by side: orange on the left, blue on the right. Each genome: two chromosomes of 40 loci.A locus's hue is the population its allele arose in; its shade, which allele it is. At the start every orange genome is all orange, every blue one all blue.Pair 1 of the 50 a run plays, drawn up close.

TargetEach generation every genome is replaced by a young from two parents in its own population, each chromosome crossed over on the way. Nothing helps or harms.Go plays 50 generations in 50 pairs of populations (100 populations).

    To finish

    • Hit the three targets. 0 of 3
    Stage B is open.
    R code
    
        

    B

    Finish Stage A to unlock this section.

    Continual migration between 2 separated populations is hard to disentangle from just a population being one. A lot of times, if there is reasonable migration between 2 locations, we don't say they're 2 populations; we just say they're one. Another common thing is to have 2 distinct populations with periodic, lumpy migration, where there are 2 ponds, and the fish in the ponds don't interbreed, except every now and again there's a flood that lets individual fish move from one pond to the other.

    One way you can look at that is because migration will involve transferring whole chromosome sets from one individual to another. That is, an individual will have one set of chromosomes from the orange population and one set of chromosomes from blue. Recombination after the initial hybridization will chunk those chromosomes up. The size of those chunks will get smaller as you have more generations since the event. And so what you're going to be doing here is having a single migration event in which a few individuals move from one population to the other, and you're going to be trying to hit concrete targets for the size of the chromosomal chunks that are present in both populations.

    Pair 1Pair 1: the two populations today.Click a genome, then another in the same population, to see where they carry the same alleles locus for locus.

    Your runsEvery run, practice or not, adds a dot: across, generations since the dispersal event; up, its average fragment length.

    TargetThe same two populations, with no steady migration: one dispersal event, some generations back. In it, a batch of genomes from each population traded places with as many from the other. None since.Go plays it in 50 pairs of populations; pair 1 is drawn up close.

      To finish

      • Hit the three targets. 0 of 3
      • Ten runs on your plot. 0 of 10
      • Click two genomes in one population that carry the same fragment of the other hue.
      Stage C is open.
      R code
      
          

      C

      Finish Stage B to unlock this section.

      Not all the alleles at all loci are created evenly. In parts A and B, we assumed that every allele at every locus was neutral. That is, the orange ones worked just as well in the blue population's environment as the blue ones worked in the orange one's, and every allele worked the same. But that's not the case. Sometimes some alleles have an effect on fitness, and so they're going to be subject to evolutionary forces other than drift, mutation and migration. Specifically, if they have an effect on fitness, they're going to be subject to selection. What's more is that the same allele producing the same phenotype might be selected against in one area and for in another. A classic example of this might be coat color in mice. Being light and sandy is really advantageous if you're in a sandy environment, like a beach, and disadvantageous if you're in a dark environment, like a forest. And so an allele that makes your fur lighter might be beneficial on a sandy beach and harmful in a dark forest. Because the phenotype can vary, the heritability can also vary, because, remember, heritability in this sense is a function of the heritability of a fitness effect with the allele, and not simply some mechanical trait of the allele.

      To that end, we're going to repeat more or less the same simulations we did in A and B, except now we're going to have one single locus we're focusing on, indicated as a little black box, at gene 20. And we're going to be able to set the selection and heritability of each variant in the 2 populations separately. You are then going to see how the frequency changes in 2 different ways: you can look at the frequency of a given allele across the genome, and the frequency over time. Importantly, as with all of these, these graphs show more than one thing. Especially with your exam coming up, make sure you focus on the fact that you can see selective sweeps in these runs, even though I'm not calling them out, along with many other processes.

      Your goal is to hit individual targets for gene 20 in terms of its frequency in the 2 populations. However, especially as you're using this to study, make sure you're looking more generally at patterns you see in the data. Think about what they mean. Try and come up with them, and talk to somebody else about whatever patterns you see in this more realistic simulation. And if you are stuck and don't understand why you're getting the right answer or wrong answer, come and talk to me. The purpose of these homeworks is to help you identify situations you don't understand, so you can learn to understand them before the exam, or actually assess your understanding.

      Pair 1Back to A: orange and blue from the start, steady migration. Now gene 20 (boxed) matters; every other gene does nothing.

      Gene by gene, 100 populations: share in blueHow much of each gene is blue, in each population: orange bars, the orange population; blue bars, the blue.

      TargetGo plays 50 pairs of populations; pair 1 is drawn up close.

        To finish

        • Hit the three targets. 0 of 3
        Stage D is open.
        R code
        
            

        D

        Finish Stage C to unlock this section.

        In reality, you don't usually have simply two populations with a single fixed migration rate between them, and they don't tend to be of equal size. For this run, you're going to have 4 populations, still color-coded: orange, blue, red, and purple. And drift is still dominating; we're going to remove selection for now. You're going to control the migration rate between any pair of populations here. You can control them by dragging the arrows to make the migration rate increase or decrease between a given pair, and you can set up the total flow. You can also set the effective population size for each population.

        Shown is going to be the chromosomes, like we did, as well as the share of ancestry from each population. We're also going to have now the homozygosity, our inbreeding statistic F. But each population will have a different level of heterozygosity; each will have a different level of inbreeding. More migration means less inbreeding. And so in the diagram below the one we've seen with the different chromosomes, you are also going to see this new FST, which basically looks at how different the populations are. The more inbreeding there is, the more alleles are drifting at random, and over time the less similar the populations will be. The more outbreeding there is, the more migration there is, the more populations will come to be similar to one another.

        What you're going to do is run the migration with the toggles you set. And then, when you are done, you're going to do 5 rounds in which you migrate them between each other, and then you drag a chromosome, an example individual, to the population of origin. As migration rate increases between pairs, you'll see that FST drops. How accurate your assignments of individuals to their parent populations is will be compared to the theoretical expectation, as well as to the FST. So you'll do this 5 times, and try and assign individuals to one another. Look for how FST for a given setup varies with your ability to do this: specifically, your accuracy and the theoretical accuracy.

        FST is measuring how different the populations are from one another. It is the inbreeding in the subpopulation relative to the total population. Migration is outbreeding. Migration makes populations the same. Drift makes them different from each other. And so FST is measuring the balance between drift, which increases homozygosity, and migration, which decreases homozygosity. When there is high homozygosity, it is easy to tell populations apart. When there is low homozygosity, it is hard to tell populations apart. This is what you are looking at, and what I'm shooting for you to understand in this target part.

        Set 1Four populations, each of N genomes: orange, blue, red and purple. At the start each is all its own colour, one allele a gene. Nothing helps or harms.Set 1: the four populations, each with a bar of its mix of colours; under them, the four pooled.

        Set 1: how differentiatedSet 1 on the diagram's square: each population's colours gene by gene (a column a gene) and its heterozygosity; on each line, FST between those two; in the middle, the four pooled and FST.Heterozygosity: the share of a genome's genes at which its two chromosomes are different colours, averaged over the population's genomes.FST: how different the populations are from each other. 0: every population the same mix at every gene. 1: each only its own colour.

        TargetThe diagram: an arrow between two populations is migration between them. Click it, then drag up or down to set m: each generation, each genome trades places with one in the other population with chance m (of two populations of different sizes, each genome of the smaller).A round: Start round sets the round's migration and holds it, with N 25 in each population, and plays 100 generations in 20 sets of four. Then ten young genomes, each born in one of set 1's populations, one at a time on the diagram: drag each to the population it came from.

          Practice, ticked at the start: your own migration and each population's N, and the same ten genomes after each run; nothing counts. Untick it to start a round.

          Your placementsEach run's FST and how many you placed right.The plot: the share placed wrong against FST; theory, the share wrong for a judge who knows set 1's colours gene by gene and places 400 young where each most likely came from.

          To finish

          • Place the ten genomes of all five rounds. 0 of 5
          That is the end of the lesson.
          Observed data: house and Spanish sparrows
          R code
          
              

          Good job!

          That is all of Lesson 17. Your completion code is below — copy it and hand it in.