Sample Inheritance with Tendency

Sample Inheritance with 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 the author
Model was written in NetLogo 5.2.0 • Viewed 103 times • Downloaded 16 times • Run 0 times
Download the 'Sample Inheritance with 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 gray 5 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 
    [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 
    [ask one-of turtles [hatch 1 [set size [size] of myself set color random 390 fd random 3 + 1]]]
  if size-preference > 0 
    [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
Sample Inheritance with Tendency.png preview Preview for 'Sample Inheritance with Tendency' over 7 years ago, by Larry Bencivengo Download

This model does not have any ancestors.

This model does not have any descendants.