This activity was inspired by two of the disciplinary core ideas in the Next Generation Science Standards: LS3.A (Inheritance of Traits) and LS3.B (Variation of Traits). Our goal was to use Scratch with the Hummingbird to create a genetics simulation. First, we will describe the simplest version of this simulation, and then we will explain how it can be expanded for more advanced students.
This simulation is based on the genetics of eye color. The dominant allele for brown eyes is represented by ‘R,’ and the recessive blue allele is represented by ‘b.’ Scratch is not case sensitive, so we could not use ‘B’ and ‘b’ (because Scratch cannot tell the difference between them). The simulation uses the random number generator to select the allele that a child receives from the mother; this is stored in the variable Gene from Mom. Similarly, the allele that the child receives from the father is stored in Gene from Dad.
Next, an if-else statement is used to determine the color of the child’s eyes. This determines the commands to the Hummingbird and the appearance of the sprite on the screen. On the robot, the servo is used to point to either “Blue Eyes” or “Brown Eyes.” The robot’s eyes turn blue when the simulation indicates that the child has the genotype for blue eyes.
Students learning about genetics for the first time can run the simulation multiple times and count the number of times that the child has blue eyes and brown eyes. They can then change the genotype of the mother and father and repeat this process. In this way, students can use the simulation to experience how the genotypes of the parents change the probability of a child with blue eyes.
More advanced students can take this simulation further. A loop can be used to run the simulation many times while a variable counts the number of blue genotypes that occur. Again, students can change the genotypes of the parents to measure how that affects the probability of a child with blue eyes.
Students could take this even further! For example, the simulation could start from grandparents instead of parents. In addition, eye color is actually more complicated than the simple Mendelian model used here. The simulation could be modified to include more alleles.