Genetic Linkage Analysis in Drosophila

Genetic Linkage Analysis in Drosophila preview image

1 collaborator

Screen_shot_2018-02-02_at_12.53.50_pm lin xiang (Author)

Tags

(This model has yet to be categorized with any tags)
Visible to everyone | Changeable by the author
Model was written in NetLogo 6.2.2 • Viewed 146 times • Downloaded 24 times • Run 0 times
Download the 'Genetic Linkage Analysis in Drosophila' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


WHAT IS IT?

This model allows students to explore the inheritance of bar eyes, yellow body color, and dumpy wings in fruit flies (Drosophila melanogaster). Students may gather data to infer whether these traits are dominant or recessive, sex-linked or autosomal. These traits are not often mentioned in the textbook, so teachers may use them to extend students' understanding after learning about the common examples (e.g., white-eyed).

HOW TO USE

  1. Select one of three cases.
  2. Click the "Start/reset" button to start or start over.
  3. Click the "Press and choose 2 parent flies" button.
  4. Choose a male and a female in the simulation window. The males are smaller and have a dark abdomen tip.
  5. Click the "cross!" button to conduct a test cross.
  6. Examine offspring phenotypes in the simulation window and the "progeny" section.

Related Models

Genetic Linkage https://sites.google.com/view/genetic-linkage/model

Find more models at https://sites.google.com/view/3d-science-abm/home

CREDITS AND REFERENCES

This model was made by Dr. Lin Xiang at the University of Kentucky.If you mention this model in a publication, we ask that you include the citations below.

Xiang, L. (2023). Genetic Linkage Analysis in Drosophila. Department of STEM Education, University of Kentucky, Lexington, KY.

CC BY-NC-SA 4.0

This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License. To view a copy of this license, visit https://creativecommons.org/licenses/by-nc-sa/4.0/.

Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

globals [x y p1 p2 population-size f-x f-y fly-ID list-1 list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9]    ;p1=selected parent 1, p2=selected parent 2,
turtles-own [c1 c2 genotype phenotype gender eye-shape wing-shape body-color]

breed [sperms sperm]
breed [eggs egg]
breed [flies a-fly]
breed [crosses cross]

to setup
  ca
  set-gametes
  fertilization
  set-tray
  output-results
  reset-ticks
end 

to set-gametes

set population-size 20 + random 16

(ifelse
  Cases = "Case 1" [              ;bar eyes.
  create-sperms population-size
  [gamete-trait
    set c1 item random 3 ["XEB" "XEb" "Y"]     ;given the three possoibilities, the gender ratio does not start with 1:1 at the beginning but brias to female
    set c2 "D"                               ;all flies are normal-winged
    set genotype word c1 c2                  ;form  genotype of gamete
    ]

  create-eggs population-size
  [gamete-trait
    set c1 item random 2 ["XEB" "XEb"]
    set c2 "D"
    set genotype word c1 c2
    ]
  ]

 Cases = "Case 2" [             ; dumpy wings
   create-sperms population-size
  [gamete-trait
    set c1 item random 2 ["XEb" "Y"]         ; Xb is normal eye trait
    set c2 item random 3 ["D" "d" "d"]        ; D and d are wing shape color alleles.
    set genotype word c1 c2
    ]

  create-eggs population-size
  [gamete-trait
    set c1 "XEb"
    set c2 item random 3 ["D" "d" "d"]
    set genotype word c1 c2
    ]
  ]



Cases = "Case 3" [             ;yellow body.
   create-sperms population-size
  [gamete-trait
    set c1 item random 3 ["XEb" "Xeb" "Y"]         ; XE is normal body color
    set c2 "D"                                   ; nomral wings
    set genotype word c1 c2
    ]

  create-eggs population-size
  [gamete-trait
    set c1 item random 2 ["XEb" "Xeb"]
    set c2 "D"
    set genotype word c1 c2
    ]
  ]
)
end 

to gamete-trait
  set shape "dot"
    set size 0.1
    setxy random-xcor random-ycor
end 

to express

  ;;Determine phenotypes based on the allele, then code the phenotypes
  ifelse member? "Y" genotype = true [set gender "male" set size 0.75 set phenotype "m-" ][set gender "female" set size 0.9 set phenotype "f-"]

  ifelse member? "D" genotype = true [set wing-shape "normal-winged" set phenotype word phenotype "lw-"][set wing-shape "dumpy-winged" set phenotype word phenotype "dw-"]

  ifelse member? "XE" genotype = true
  [(ifelse
    member? "B" genotype = true and member? "b" genotype = false
    [set eye-shape "bar eye" set phenotype word phenotype "b-"]

    member? "B" genotype = false and member? "b" genotype = true
    [set eye-shape "normal eye" set phenotype word phenotype "r-"]

     member? "B" genotype = true and member? "b" genotype = true
    [set eye-shape "kidney eye" set phenotype word phenotype "h-"])

    set body-color "normal body" set phenotype word phenotype "lb"]

  [(ifelse
    member? "B" genotype = true and member? "b" genotype = false
    [set eye-shape "bar eye" set phenotype word phenotype "b-"]

    member? "B" genotype = false and member? "b" genotype = true
    [set eye-shape "normal eye" set phenotype word phenotype "r-"]

     member? "B" genotype = true and member? "b" genotype = true
    [set eye-shape "kidney eye" set phenotype word phenotype "h-"])

    set body-color "yellow body" set phenotype word phenotype "yb"]





  ;;Determine the shape and color using phenotype codes
  if phenotype = "m-lw-r-lb" [set shape "fly-m-r-lw"]
  if phenotype = "m-lw-r-yb" [set shape "fly-m-r-lw" set color 48.5]  ;set yellow body color
  if phenotype = "m-dw-r-lb" [set shape "fly-m-r-dp"]
  ;if phenotype = "m-dw-r-yb" [set shape "fly-m-r-dp" set color 48.5]
  if phenotype = "m-lw-b-lb" [set shape "fly-m-b-lw"]
  ;if phenotype = "m-lw-b-yb" [set shape "fly-m-b-lw" set color 48.5]


  if phenotype = "f-lw-h-lb" [set shape "fly-f-h-lw"]
  if phenotype = "f-lw-r-lb" [set shape "fly-f-r-lw"]
  if phenotype = "f-lw-r-yb" [set shape "fly-f-r-lw" set color 48.5]
  if phenotype = "f-dw-r-lb" [set shape "fly-f-r-dp"]
 ; if phenotype = "f-dw-r-yb" [set shape "fly-f-r-dp" set color 48.5]
  if phenotype = "f-lw-b-lb" [set shape "fly-f-b-lw"]
  ;if phenotype = "f-lw-b-yb" [set shape "fly-f-b-lw" set color 48.5]
end 

to fertilization

  ask eggs
  [let mate one-of sperms
    if mate != nobody
    [hatch-flies 1
     [set color 28             ;set light body color, some will be overwritten to a black body color in express
       set heading 0
       set genotype word genotype [genotype] of mate
       express
       set-position
      ]
      ask mate [die]
      die
  ]]

  ask sperms [die]
  ask eggs [die]
end 

to set-tray
  ask patches [set pcolor 102 + random-float 0.5]
  ask patches with [pxcor >= max-pxcor - 1] [set pcolor 87]

  create-crosses 1
   [set shape "x"
    setxy max-pxcor - 0.5 max-pycor / 2
    set size 0.5
    set color 35]

  create-crosses 1 [
    set shape "female"
    set heading 45
    setxy max-pxcor + 0.25 5
    set size 0.75
    set color 0]

 create-crosses 1 [
    set shape "male"
    set heading 45
    setxy max-pxcor + 0.25 min-pycor + 0.25
    set size 0.75
    set color 0]
end 

to set-position
  setxy random 10 random 7
  if any? other flies-here [set-position]
end 

;====================================================================================

to go

  ifelse count flies != 2
[output-print ""
 output-print "Please first choose two parent flies."]
[
    gametogenesis
    fertilization
]
end 

to pick

;clear-output
  if mouse-inside? [
    if mouse-down? [
      set x round mouse-xcor set y round mouse-ycor
      ask flies with [xcor = x and ycor = y]
        [ if gender = "male"
            [ifelse count flies with [gender = "male" and pxcor >  max-pxcor - 1] > 0
            [set p1 "Opse! You have chosen a male."]
            [set size 1.25 setxy max-pxcor - 0.5 1.5

            let dad flies with [pxcor >= max-pxcor - 1 and gender = "male"]
            set p2 [eye-shape] of dad
            set p2 word p2 " "
            set p2 word p2 [wing-shape] of dad
            set p2 word p2 " "
            set p2 word p2 [body-color] of dad
          ]]

          if gender = "female"
            [ifelse count flies with [pxcor > max-pxcor - 1 and gender = "female"] > 0
            [set p2 "Opse! You have chosen a female."]
            [set size 1.25 setxy max-pxcor - 0.5 4.5

             let mom flies with [pxcor >= max-pxcor - 1 and gender = "female"]
             set p1 [eye-shape] of mom
             set p1 word p1 " "
             set p1 word p1 [wing-shape] of mom
             set p1 word p1 " "
             set p1 word p1 [body-color] of mom
          ]]
  ]]]


 if count flies with [pxcor >= max-pxcor - 1] = 2 [
  ask flies with [pxcor < max-pxcor - 1 ] [die]
  ask eggs [die]
  ask sperms [die]
  stop
  ]
end 

to gametogenesis

set population-size 4 * (14 + random 4)

  ;set eggs

  let mom one-of flies with [gender = "female"]

  (ifelse       ;set XEB gene
    member? "XEB" [genotype] of mom = true and member? "XEb" [genotype] of mom = false and member? "Xeb" [genotype] of mom = false   ;XEBXEB
     [create-eggs population-size [set genotype "XEB" gamete-trait ]]

    member? "XEB" [genotype] of mom = false and member? "XEb" [genotype] of mom = true and member? "Xeb" [genotype] of mom = false   ;XEbXEb
     [create-eggs population-size [set genotype "XEb" gamete-trait ]]

    member? "XEB" [genotype] of mom = false and member? "XEb" [genotype] of mom = false and member? "Xeb" [genotype] of mom = true   ;XebXeb
     [create-eggs population-size [set genotype "Xeb" gamete-trait ]]

    member? "XEB" [genotype] of mom = true and member? "XEb" [genotype] of mom = true and member? "Xeb" [genotype] of mom = false   ;XEBXEb
     [create-eggs 0.5 * population-size [set genotype "XEB" gamete-trait ]
      create-eggs 0.5 * population-size [set genotype "XEb" gamete-trait ]]

    member? "XEB" [genotype] of mom = true and member? "XEb" [genotype] of mom = false and member? "Xeb" [genotype] of mom = true   ;XEBXeb
     [create-eggs 0.5 * population-size [set genotype "XEB" gamete-trait ]
      create-eggs 0.5 * population-size [set genotype "Xeb" gamete-trait ]]

    member? "XEB" [genotype] of mom = false and member? "XEb" [genotype] of mom = true and member? "Xeb" [genotype] of mom = true   ;XEbXeb
     [create-eggs 0.5 * population-size [set genotype "XEb" gamete-trait ]
      create-eggs 0.5 * population-size [set genotype "Xeb" gamete-trait ]]

   )

  (ifelse        ;Set D gene
    member? "D" [genotype] of mom = true and member? "d" [genotype] of mom = false ;DD
    [ask eggs [set genotype word genotype "D"]]

    member? "D" [genotype] of mom = false and member? "d" [genotype] of mom = true ;dd
    [ask eggs [set genotype word genotype "d"]]

    member? "D" [genotype] of mom = true and member? "d" [genotype] of mom = true ;Dd
    [ask n-of (0.5 * count eggs with [genotype = "XEb"]) eggs with [genotype = "XEb"] [set genotype word genotype "D"]  ; XEbD  50%
      ask eggs with [genotype = "XEb"] [set genotype word genotype "d"]])                                                 ; XEbd 50%



   ; set sperms

   let dad one-of flies with [gender = "male"]

   (ifelse

      member? "XEB" [genotype] of dad = true and member? "XEb" [genotype] of dad = false and member? "Xeb" [genotype] of dad = false    ;XEBY
           [create-sperms 0.5 * population-size [set genotype "XEB" gamete-trait ] create-sperms 0.5 * population-size [set genotype "Y" gamete-trait ]]

      member? "XEb" [genotype] of dad = true and member? "XEB" [genotype] of dad = false and member? "Xeb" [genotype] of dad = false    ;XEbY
           [create-sperms 0.5 * population-size [set genotype "XEb" gamete-trait ] create-sperms 0.5 * population-size [set genotype "Y" gamete-trait ]]

      member? "XEb" [genotype] of dad = false and member? "XEB" [genotype] of dad = false and member? "Xeb" [genotype] of dad = true    ;XebY
           [create-sperms 0.5 * population-size [set genotype "Xeb" gamete-trait ] create-sperms 0.5 * population-size [set genotype "Y" gamete-trait ]])



  (ifelse        ;Set D gene

   member? "D" [genotype] of dad = true and member? "d" [genotype] of dad = false ;DD
    [ask sperms [set genotype word genotype "D"]]

   member? "d" [genotype] of dad = true and member? "D" [genotype] of dad = false ;dd
    [ask sperms [set genotype word genotype "d"]]

   member? "d" [genotype] of dad = true and member? "D" [genotype] of dad = true ;Dd
     [ask n-of (0.5 * count sperms with [genotype = "XEB"]) sperms with [genotype = "XEB"] [set genotype word genotype "D"]  ; XEBD  50%
      ask sperms with [genotype = "XEB"] [set genotype word genotype "d"]                                                    ; XEBd 50%

      ask n-of (0.5 * count sperms with [genotype = "XEb"]) sperms with [genotype = "XEb"] [set genotype word genotype "D"]  ; XEbD  50%
      ask sperms with [genotype = "XEb"] [set genotype word genotype "d"]                                                    ; XEbd 50%

      ask n-of (0.5 * count sperms with [genotype = "Xeb"]) sperms with [genotype = "Xeb"] [set genotype word genotype "D"]  ; XebD  50%
      ask sperms with [genotype = "Xeb"] [set genotype word genotype "d"]                                                    ; Xebd 50%

      ask n-of (0.5 * count sperms with [genotype = "Y"]) sperms with [genotype = "Y"] [set genotype word genotype "D"]  ; YD  50%
      ask sperms with [genotype = "Y"] [set genotype word genotype "d"]])                                               ; Yd 50%

  ask flies [die]
end 

to output-results

  (ifelse

   Cases = "Case 1" [
  output-print "Female flies:  Bigger in size without a dark genitalia at the tip of the abdomen."
  output-print "Male flies:  Smaller in size with a dark genitalia at the tip of the abdomen."
  output-print ""
  output-print "Guiding Questions:"
  output-print "   Are the eye shape traits inherited through incomplete dominance or multiple alleles?"
  output-print "   Are the eye shape traits sex-linked or autosomal?"
    ]

Cases = "Case 2" [
  output-print "Female flies:  Bigger in size without a dark genitalia at the tip of the abdomen."
  output-print "Male flies:  Smaller in size with a dark genitalia at the tip of the abdomen."
  output-print ""
  output-print "Guiding Questions:"
  output-print "   Is the dumpy wing trait dominant or recessive?"
  output-print "   Is the dumpy wing trait sex-linked or autosomal?"
  ]

 Cases = "Case 3" [
  output-print "Female flies:  Bigger in size without a dark genitalia at the tip of the abdomen."
  output-print "Male flies:  Smaller in size with a dark genitalia at the tip of the abdomen."
  output-print ""
  output-print "Guiding Questions:"
  output-print "   Is the yellow body trait dominant or recessive?"
  output-print "   Is the yellow body trait sex-linked or autosomal?"
  ]
    )
end 

to set-lists


  if any? flies with [xcor <= 9][
         set list-1 [who] of flies with [phenotype = "m-lw-r-lb" and xcor < max-pxcor - 1]
         set list-2 [who] of flies with [phenotype = "m-lw-r-yb" and xcor < max-pxcor - 1]
         set list-1 sentence list-1 list-2

         set list-3 [who] of flies with [phenotype = "m-dw-r-lb" and xcor < max-pxcor - 1]
         set list-4 [who] of flies with [phenotype = "m-lw-b-lb" and xcor < max-pxcor - 1]
         set list-3 sentence list-3 list-4
         set list-1 sentence list-1 list-3

         set list-5 list-1



         set list-1 [who] of flies with [phenotype = "f-lw-r-lb" and xcor < max-pxcor - 1]
         set list-2 [who] of flies with [phenotype = "f-lw-r-yb" and xcor < max-pxcor - 1]
         set list-1 sentence list-1 list-2

         set list-3 [who] of flies with [phenotype = "f-dw-r-lb" and xcor < max-pxcor - 1]
         set list-4 [who] of flies with [phenotype = "f-lw-b-lb" and xcor < max-pxcor - 1]
         set list-3 sentence list-3 list-4
         set list-1 sentence list-1 list-3

         set list-6 [who] of flies with [phenotype = "f-lw-h-lb" and xcor < max-pxcor - 1]
         set list-1 sentence list-1 list-6

         set list-1 sentence list-1 list-5



    sorting
      ]
end 

to sorting

   set f-x 0
        set f-y max-pycor
        set fly-ID 0

        repeat length list-1
        [ask flies with [who = item fly-ID list-1] [setxy f-x f-y]
          ifelse f-y > 0 [set f-y f-y - 1][set f-y max-pycor set f-x f-x + 1]
          set fly-ID fly-ID + 1 ]
end 

There are 4 versions of this model.

Uploaded by When Description Download
lin xiang almost 2 years ago Add the incomplete dominance of eye shape Download this version
lin xiang almost 2 years ago Add notes Download this version
lin xiang almost 2 years ago Fix info typos Download this version
lin xiang almost 2 years ago Initial upload Download this version

Attached files

File Type Description Last updated
Genetic Linkage Analysis in Drosophila.png preview Preview for 'Genetic Linkage Analysis in Drosophila' almost 2 years ago, by lin xiang Download

This model does not have any ancestors.

This model does not have any descendants.