MIHS Sample for Inheritance and Tendency

MIHS Sample for Inheritance and Tendency preview image

1 collaborator

Larry_bencivengo Larry Bencivengo (Author)

Tags

(This model has yet to be categorized with any tags)
Visible to everyone | Changeable by everyone
Model was written in NetLogo 5.2.0 • Viewed 110 times • Downloaded 16 times • Run 0 times
Download the 'MIHS Sample for Inheritance and Tendency' modelDownload this modelEmbed this model

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


Comments and Questions

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

Click to Run Model

to setup                 ;; create 10 gray kings of size 5
  clear-all
  ask patches [set pcolor white]
  create-turtles 10 [set shape "chess king" set size 5 set color gray fd random 5]
end 

to go                    ;; hatch a new king that inherits its parent's size, plus or minus a random amount
  
  if size-preference < 0 ;; new kings will be smaller than parent
    [ask one-of turtles [hatch 1 [set size [size] of myself + random (size-preference - 1) set color random 390 fd random 3 + 1]]]
    
  if size-preference = 0 ;; new kings will be the same size as parent
    [ask one-of turtles [hatch 1 [set size [size] of myself set color random 390 fd random 3 + 1]]]
    
  if size-preference > 0 ;; new kings will be larger than parent
    [ask one-of turtles [hatch 1 [set size [size] of myself + random (size-preference + 1) set color random 390 fd random 3 + 1]]]
end 

There is only one version of this model, created over 7 years ago by Larry Bencivengo.

Attached files

File Type Description Last updated
MIHS Sample for Inheritance and Tendency.png preview Preview for 'MIHS Sample for Inheritance and Tendency' over 7 years ago, by Larry Bencivengo Download

This model does not have any ancestors.

This model does not have any descendants.