Course Icon


Biology Lab: AP Investigation #12 - Habitat Selection

SO Icon

Lab Exercise

Biology Lab: Habitat Selection

Concept: Animals respond to different factors in their environments, such as attractive food sources or repulsive chemicals.

Goal: To observe the movement of fruit flies in response to different substances.

AP Exam preparation -- Doing the AP version of this lab:

Please read through the 2012 AP Biology Lab Manual, Investigation #12: Fruit Fly Behavior. This lab presents some challenges for parents and students who may not wish to work with fruit flies; however, if you can collect sufficient fruit flies (see note below), you should be able to carry out the investigation with minimal additional equipment. Of course, if you are able to arrange to perform the AP lab with a local homeschool group or a biology tutor, then you should do so.

Fruit Fly collection:

Put about 1/4 cup apple cider vinegar in the bottom of a 2L soda bottle, and place a funnel in the top of the bottle. Leave the bottle outside in a warm place overnight. Check the bottle each morning, and collect any living fruit flies. Place these in a second bottle containing damp cotton sprinkled with sugar (or soaked in a small amount of sugar water); cover this bottle with mesh to prevent escape. Continue collection until you have enough fruit flies to conduct the experiment.

If you need to "slow down" fruit flies to handle them more easily, put your container (sealed, of course) in the refrigerator for 30 minutes.

Alternative Lab: Brine Fish Habitat Selection

There is no Illustrated Guide to Home Biology Experiments alternative lab for this exercise.

If you are unable to do AP lab #9 as written, you may perform an alternative lab involving habitat selection using bring shrimp (available as fish food at pet stores).

Goal: To observe Brine Shrimp response to changes in habitat

Materials and Equipment:


  1. Run the control setup by placing 50mL of solution containing about 1/4 of your shrimp population in each strip of Tygon tube. Cork the ends of each tube and place it horizontally on a table, with three clamps set up to divide it into four equal sections. Do not close the clamps until instructed.
  2. Control run: cover #1 tube with opaque cloth across all four sections.
  3. Light gradient run: over the first section of #2 tube lay 8 layers of screen. Over the second section, lay 4 layers of screen. Over the third section, put 2 layers of screen. Leave the final section uncovered. Place a light source above the tubing; try to use one that will not heat the tubing and its contents
  4. Temperature gradient: Place a hot water bottle filled with water at 60 °C at one end and a bag of ice at the other end of the tube.
  5. pH gradient: The lab calls for KOH; it isn't a household commodity. Use a few grains -- a very small amount of powdered lye (NaOH) if you have it, otherwise use baking soda instead of the KOH. Removing the cork, put this in one end of the tube. At the other end, put a small amount of powdered ascorbic acid if you have it, or lemon juice.
  • Let each tube sit for 30 minutes once you have set up the environment. At the end of thirty minutes, while holding the corks in place so nothing leaks, close the clamps to prevent further migration by the brine shrimp.
  • Carefully dump each section of the tube into one of 4 test tubes (4 sets of 4 testtubes = 16 altogether). Label the tubes by tube type and location. For the temperature gradient tubing, immediately measure and record the temperature of water in each tube. For the pH gradient, immediately measure and estimate the pH of the solution in the tube.
  • Pour the contents of a test tube into a flat plate or Petri dish. Count the number of brine shrimp in each test tube at least 3 times (5 is better), and calculate the average.


    1. Figure out a way to organize your numerical data in tables to display any trends (such as denser populations near light-exposed ends of the tube, or toward alkaline solutions and away from acid, according to what you actually observe.
    2. Figure out a way to organize this information in histograms to graphically highlight any trends.