Row

The Bugs

Heritability:

Generation:

The Analyses

Left Field:

Mean:

Right Field:

Mean:

Enter spot count data for up to 100 families. Use the tab key to move to the next cell or row.

Best-fit line:

Row

Overview

Bugsville challenges you to design and run experiments to estimate the heritability of a quantitative trait and to predict how a population will respond to selection. The organisms in the population you will study are ladybugs. The trait you will analyze is number of spots. The analytical tools you’ll need are described briefly here, and discussed in more detail in Chapter 9 of my book, Evolutionary Analysis.

Disclaimer: I don’t know anything about the genetics of spot number in real ladybugs! In the individual-based model used here, spot number can vary from zero to fourteen and arises from the combined influence of several genes of small effect plus a random environmental component.

Use the tabs in this section for a quick look at what you can do with Bugsville. Please use this link for a detailed tutorial.

When you get to the later portions of the exercise described here, you may find this worksheet useful.

1) Bugs

In the pane labeled The Bugs you should see a darker gray rectangle at the upper left, containing hundreds of dots. This rectangle is Left Field. Each of the dots in Left Field represents a ladybug. The larger, colored dots are adults. The smaller, gray dots are larvae. To get a closer look at an individual and—if it is an adult—count its spots, click on the dot and hold.

When you click the Start button at the bottom right of the Bugs pane, you’ll see the ladybugs move around, bump into each other and make babies, and die. Go ahead and try it.

You can drag individual ladybugs to any location in Left Field. You can also drag them to Right Field or any of the ten breeding pens below the fields. By clicking and dragging inside one of the fields or pens—not on a bug it contains—you can select a group of bugs, then drag the group anywhere you’d like.

If you drag bugs or groups into the light gray area around the fields and pens, you’ll see the bugs fall below the breeding pens. You can drag bugs one at a time back into a field or pen. But once you click Start, any bugs not in a field or pen will vanish.

2) Choose Adventure

At the bottom of the Bugs pane, you should see a set of radio buttons labeled Heritability. This determines the heritability of spot count in the starting Left Field ladybug population. You may want to practice the techniques we will cover with the heritability set to Low, Medium, or High. Your main challenge will be to estimate the heritability when it has been set to an unknown random value between 0 and 1.

Note: You can reset the simulation any time by clicking on Reset at the upper right of the Bugsville window. This will create a new population of bugs with a new, randomly selected heritability. Any work you’ve done on a previous population will be irrelevant to the new one. Please be aware that on a mobile device, the Bugsville window may refresh—and thus reset—if you open another app, then return to your web browser.

3) Analyze Populations

Click on several of the adult ladybugs in Left Field and count their spots. What is the highest spot count you can find? The lowest? What is a typical number of spots?

Now notice the pane labeled The Analyses. Make sure the Analyze Populations tab is active. This tab contains histograms revealing the distribution of spot counts in the Left Field (top) and Right Field (bottom) populations. If you drag a few bugs from Left Field to Right Field, you should see both histograms update. If you start the simulation, you’ll see that the histograms update continuously.

Looking at the histogram for Left Field, does it confirm (or expand) your impression of how how much the bugs in Left Field vary in spot count?

Your next task is to learn how much of the variation in the Left Field population is due to differences in the genes the bugs inherited from their parents. Before you start, you may want to pick a different heritability or refresh the window. Once you start breeding bugs to get data on families, remember that if your browser refreshes, all your work will be lost.

4) Analyze Familes

One way to assess whether variation among individuals is due to genetic differences is to let them reproduce, then note whether the offspring resemble their parents. In the Analyses pane, click on the Analyze Families tab. You should see an empty table where you can record data on parents and offspring. And you should see an empty graph.

Drag a pair of adults into one of the breeding pens. Note how many spots each has and record the numbers in the Family 1 row of the data table. Make sure the ladybugs are touching each other. You don’t need to worry about which ones are female and which ones are male. Any of our ladybugs can mate with any other!

Run the simulation just long enough for your pair to make larvae, then stop it. Now move the adults out of the pen—so that when the babies grow up, you don’t lose track of who is who. You can return the adults to Left Field if you like, or you can just throw them out by dragging them into the light gray area around the pens.

Finally, start the simulation again and run it just long enough for the babies to grow up. Note how many spots each has and record the numbers in the data table. Once you’ve typed the last number, then pressed the Tab, Enter, or Return key, a dot will appear in the graph showing the average spot count of the offspring, also known as the “Midoffspring” value, versus the average spot count of the parents, also knows as the “Midparent” value.

5) Estimate Heritability

Following the instructions in the previous tab, collect data on at least 20 families of ladybugs. The more families you include, the more accurate your estimate will be.

As soon as you have begun entering data for the third family, the graph in the Analyze Families tab will show the best-fit line through your data points. The line will update as you add more data. The equation for the line, in slope-intercept form, appears to the right of the graph. The slope is the number in front of “x”. The equation for the line is calculated using least-squares linear regression—the standard method for finding best-fit lines.

We can take the slope of the best-fit line for a parent-offspring regression—like the one you have just produced—as an estimate of the heritability of the trait in question. In principle, this number falls somewhere between 0 and 1. It tells us how much of the variation among the parents is due to differences in the genes they carry (as opposed to random environmental effects).

6) Select

Once you have an estimate for the heritability of spot count in your Left Field population, go back to the Analyze Populations tab in the Analyses pane. Make a note of the mean spot count for the Left Field ladybugs. The mean appears below the graph, and it is indicated by a white dot on the horizontal axis of the histogram.

Now you can perform a mass selection experiment. Decide whether you will select for high spot count or low spot count. Move at least a dozen adult ladybugs with the desired spot counts to Right Field. Make sure they are touching each other, so that when you start the simulation they will mate. Before you start the simulation, make a note of the mean spot count in your newly-established Right Field population.

7) Predict Response

You may find this worksheet useful for the calculations you are about to do.

The selection differential is the difference between mean of your Right Field population—that is, your selected population—versus the mean of the Left Field population before you moved any bugs to Right Field. The selection differential is a measure of how stringently you have filtered the Left Field population in choosing the founders of your Right Field population.

You can predict the response to selection by multiplying your selection differential by your estimate of the heritability. The response to selection is the difference between the mean of the offspring of the selection parents versus what the mean would have been if you had used all of the bugs in Left Field as founders of the right field population.

8) Check Prediction

Once you have calculated the predicted the response to selection, start the simulation. Run it until the Generation counter near the Start button turns to 2. This is enough time for the Right Field population to reach its maximum possible size, and for all the founders of the Right Field population to be replaced by their descendants.

Stop the simulation and note the mean of the Right Field population. Calculate the actual response to selection as the difference between this mean and the mean of the Left Field population before selection. How well does the actual response to selection match your prediction?

Before deciding on a firm answer to this question, you may want to compare your results to those of your classmates. Prepare a scatterplot showing the actual response versus the predicted response. On the whole, how well does the machinery of quantitative genetics allow us to predict how populations will evolve?

License

I make no warranties or guarantees about the quality of Bugsville or the accuracy of the simulations it runs. Please have fun with it.

Bugsville is free to use. Please share the link. You may not copy, re-post, reuse, or sell Bugsville.

If you use Bugsville, or if you have comments or suggestions, please let me know with an email to herronjc at uw.edu.

Made with PixiJS, Chart.js, Tabulator, Regression-js, and flexdashboard. Thanks to the individuals and communities who created these tools!

A ladybug Bugsville 2.0 © 2023 by Jon C. Herron — All Rights Reserved.