IDEAS home Printed from https://ideas.repec.org/a/jas/jasssj/2016-128-2.html
   My bibliography  Save this article

Improving Execution Speed of Models Implemented in NetLogo

Author

Abstract

NetLogo has become a standard platform for agent-based simulation, yet there appears to be widespread belief that it is not suitable for large and complex models due to slow execution. Our experience does not support that belief. NetLogo programs often do run very slowly when written to minimize code length and maximize clarity, but relatively simple and easily tested changes can almost always produce major increases in execution speed. We recommend a five-step process for quantifying execution speed, identifying slow parts of code, and writing faster code. Avoiding or improving agent filtering statements can often produce dramatic speed improvements. For models with extensive initialization methods, reorganizing the setup procedure can reduce the initialization effort in simulation experiments. Programming the same behavior in a different way can sometimes provide order-of-magnitude speed increases. For models in which most agents do nothing on most time steps, discrete event simulation—facilitated by the time extension to NetLogo—can dramatically increase speed. NetLogo’s BehaviorSpace tool makes it very easy to conduct multiple-model-run experiments in parallel on either desktop or high performance cluster computers, so even quite slow models can be executed thousands of times. NetLogo also is supported by efficient analysis tools, such as BehaviorSearch and RNetLogo, that can reduce the number of model runs and the effort to set them up for (e.g.) parameterization and sensitivity analysis.

Suggested Citation

  • Steven F. Railsback & Daniel Ayllón & Uta Berger & Volker Grimm & Steven Lytinen & Colin Sheppard & Jan Thiele, 2017. "Improving Execution Speed of Models Implemented in NetLogo," Journal of Artificial Societies and Social Simulation, Journal of Artificial Societies and Social Simulation, vol. 20(1), pages 1-3.
  • Handle: RePEc:jas:jasssj:2016-128-2
    as

    Download full text from publisher

    File URL: https://www.jasss.org/20/1/3/3.pdf
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Ayllón, Daniel & Railsback, Steven F. & Vincenzi, Simone & Groeneveld, Jürgen & Almodóvar, Ana & Grimm, Volker, 2016. "InSTREAM-Gen: Modelling eco-evolutionary dynamics of trout populations under anthropogenic environmental change," Ecological Modelling, Elsevier, vol. 326(C), pages 36-53.
    Full references (including those not matched with items on IDEAS)

    Citations

    Citations are extracted by the CitEc Project, subscribe to its RSS feed for this item.
    as


    Cited by:

    1. Zhiqiang Wang & Jing Huang & Huimin Wang & Jinle Kang & Weiwei Cao, 2020. "Analysis of Flood Evacuation Process in Vulnerable Community with Mutual Aid Mechanism: An Agent-Based Simulation Framework," IJERPH, MDPI, vol. 17(2), pages 1-21, January.
    2. Drechsler, Martin & Wätzold, Frank & Grimm, Volker, 2022. "The hitchhiker's guide to generic ecological-economic modelling of land-use-based biodiversity conservation policies," Ecological Modelling, Elsevier, vol. 465(C).
    3. Yi Tang & Mingyu Liu & Zhanli Sun, 2020. "Indirect Effects of Grazing on Wind-Dispersed Elm Seeds in Sparse Woodlands of Northern China," Land, MDPI, vol. 9(12), pages 1-11, December.
    4. An, Li & Grimm, Volker & Sullivan, Abigail & Turner II, B.L. & Malleson, Nicolas & Heppenstall, Alison & Vincenot, Christian & Robinson, Derek & Ye, Xinyue & Liu, Jianguo & Lindkvist, Emilie & Tang, W, 2021. "Challenges, tasks, and opportunities in modeling agent-based complex systems," Ecological Modelling, Elsevier, vol. 457(C).

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Grimm, Volker & Berger, Uta, 2016. "Robustness analysis: Deconstructing computational models for ecological theory and applications," Ecological Modelling, Elsevier, vol. 326(C), pages 162-167.
    2. Grimm, Volker & Berger, Uta, 2016. "Structural realism, emergence, and predictions in next-generation ecological modelling: Synthesis from a special issue," Ecological Modelling, Elsevier, vol. 326(C), pages 177-187.
    3. Jager, Henriette I. & DeAngelis, Donald L., 2018. "The confluences of ideas leading to, and the flow of ideas emerging from, individual-based modeling of riverine fishes," Ecological Modelling, Elsevier, vol. 384(C), pages 341-352.
    4. Salecker, Jan & Dislich, Claudia & Wiegand, Kerstin & Meyer, Katrin M. & Pe'er, Guy, 2019. "EFForTS-LGraf: A landscape generator for creating smallholder-driven land-use mosaics," EFForTS Discussion Paper Series 29, University of Goettingen, Collaborative Research Centre 990 "EFForTS, Ecological and Socioeconomic Functions of Tropical Lowland Rainforest Transformation Systems (Sumatra, Indonesia)".
    5. Drechsler, Martin & Wätzold, Frank & Grimm, Volker, 2022. "The hitchhiker's guide to generic ecological-economic modelling of land-use-based biodiversity conservation policies," Ecological Modelling, Elsevier, vol. 465(C).
    6. Alexandra I. Klimenko & Diana A. Vorobeva & Sergey A. Lashin, 2023. "A New Visualization and Analysis Method for a Convolved Representation of Mass Computational Experiments with Biological Models," Mathematics, MDPI, vol. 11(12), pages 1-19, June.
    7. Malishev, Matthew & Kramer-Schadt, Stephanie, 2021. "Movement, models, and metabolism: Individual-based energy budget models as next-generation extensions for predicting animal movement outcomes across scales," Ecological Modelling, Elsevier, vol. 441(C).
    8. Dick, D.D.C. & Ayllón, D., 2017. "FloMan-MF: Floodplain Management for the Moor Frog − a simulation model for amphibian conservation in dynamic wetlands," Ecological Modelling, Elsevier, vol. 348(C), pages 110-124.

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:jas:jasssj:2016-128-2. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Francesco Renzini (email available below). General contact details of provider: .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.