Final Project
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
WHAT IS IT?
This section could give a general understanding of what the model is trying to show or explain.
HOW IT WORKS
This section could explain what rules the agents use to create the overall behavior of the model.
HOW TO USE IT
This section could explain how to use the model, including a description of each of the items in the interface tab.
THINGS TO NOTICE
This section could give some ideas of things for the user to notice while running the model.
THINGS TO TRY
This section could give some ideas of things for the user to try to do (move sliders, switches, etc.) with the model.
EXTENDING THE MODEL
This section could give some ideas of things to add or change in the procedures tab to make the model more complicated, detailed, accurate, etc.
NETLOGO FEATURES
This section could point out any especially interesting or unusual features of NetLogo that the model makes use of, particularly in the Procedures tab. It might also point out places where workarounds were needed because of missing features.
RELATED MODELS
This section could give the names of models in the NetLogo Models Library or elsewhere which are of related interest.
CREDITS AND REFERENCES
This section could contain a reference to the model's URL on the web if it has one, as well as any other necessary credits or references.
Comments and Questions
breed [banks bank] breed [consumers consumer] undirected-link-breed [loanlinks loanlink] undirected-link-breed [banklinks banklink] banks-own [ bank-reserves bank-standards ;;this denotes whether or not a bank is willing to take on a high risk customer ] consumers-own [ reliability ;;a consumer's ability to pay back loans loan ] to setup ca setup-banks setup-consumers network-banks end to setup-banks create-banks 10 [set bank-reserves random 30 set shape "circle" set color red set bank-standards random 100 move-to one-of patches] end to setup-consumers create-consumers 100 [set reliability random 100 set shape "sheep" set color blue move-to one-of patches] end to network-banks ask banks [create-banklink-with one-of other banks] end to bank-failure if count my-banklinks > 0 [ask one-of banklink-neighbors [set bank-reserves bank-reserves - interbank-loan-amount]] if count my-banklinks > 0 [ask one-of banklink-neighbors [set bank-reserves bank-reserves - interbank-loan-amount]] if count my-banklinks > 0 [ask one-of banklink-neighbors [set bank-reserves bank-reserves - interbank-loan-amount] ] ;;repeat this process of subtracting money lost by banks from interbank loans as many times ;;as seems appropriate die end to go ask banks [if bank-reserves <= 0 [bank-failure]] ;;banks fail when they're out of reserves ask consumers [right random 180 left random 180 fd 1] ask consumers [if count my-loanlinks = 0 [network-with-bank]] ask consumers [if reliability < 20 [if random 100 < 75 [if count my-links > 0 [ask one-of loanlink-neighbors [loseloan] set loan 0 die]]]] if count banks = 0 [stop] tick end to loseloan set bank-reserves bank-reserves - loan-amount end to network-with-bank if count banks > 0 [ if loan = 0 [ask my-links [die] create-loanlink-with one-of banks ask one-of loanlink-neighbors [set bank-reserves bank-reserves - loan-amount] set loan loan-amount]] end
There are 2 versions of this model.
Attached files
No files
This model does not have any ancestors.
This model does not have any descendants.