NetLogo banner

NetLogo Publications
Contact Us

Modeling Commons

Beginners Interactive NetLogo Dictionary (BIND)
NetLogo Dictionary

User Manuals:
Farsi / Persian


NetLogo User Community Models

(back to the NetLogo User Community Models)

[screen shot]

If clicking does not initiate a download, try right clicking or control clicking and choosing "Save" or "Download".

Try It in NetLogo Web


This model presents a DEB-IBM (Individual-based model incorporated with a dynamic energy budget) for southern elephant seals, using IBM data from longitudinal studies on Macquarie Island. DEB parameters are derived from Kooijman’s toolbox, DEBtool (; more detail provided in associated manuscript). The full model description, following the ODD (Overview, Design concepts and Details) protocol for describing individual based models (Grimm et al. 2006, Grimm et al. 2010) is published in Goedegebuure et al. (2018 PLOS ONE; Modelling southern elephant seals Mirounga leonina using an individual-based model coupled with a dynamic energy budget; DOI 10.1371/journal.pone.0194950). This publication also lists, in detail, all parameters used in this model.


To learn the basics of modelling with NetLogo, please see the NetLogo general model information and handbook at; specific information on individual-based modelling in NetLogo can also be found in the book “Agent-based and individuals-based modelling. A practical introduction” by Railsback and Grimm (2011); an introduction to dynamic energy budget theory is found in the book “Dynamic energy budget theory for metabolic organisation” by Kooijman (2010).

Once NetLogo has been opened, three tabs can be seen; Interface, Info and Code. The main tab used for running of the models, is the Interface. Here all global parameters are set, and outcomes visualised. The Info tab can include information on the model, its use, or important notes. The Code tab contains the procedures implemented in the model (detailed explanations of these procedures can be found in the ODD description of the model).
Using the DEB-IBM can be done at two levels. Minimal modelling experience is required for the first level of interaction, which is through the interface only. A deeper understanding of modelling and the programming language are required when alterations are made to the code as well as the interface. This may be required, for example, when the model is to be adjusted to fit different species, or when the model (currently non-spatial) is enhanced to become spatially explicit.

The first thing to note when opening the model, is that it is visually quite large; you can zoom in (Ctrl, +) and out (Ctrl, -) to get to the optimal viewing of the model on your monitor. The buttons (purple) are clickable modelling actions; inputs on the interface (green) are global and used in the code. These can be in the form of set values, variable sliders or switches (on or off). All model outputs visualised on the interface are within yellow frames and can be in the form of plots or values.
**Please note that the sliders and switches on the interface are sensitive to scrolling with the mouse.** If you need to scroll through the interface (to get from top to bottom) please use the bar on the side of the screen to avoid inadvertently modifying set parameter values.

The standard term for individual agents in NetLogo is ‘turtles’ – this can be changed to whatever name you would like it to be in the initialisation section of the code (see the NetLogo manual; Breeds). For simplicity sake we have chosen not to do so. We do however recommend it when a model is created for multiple species which follow different procedures.


The most important buttons on the interface are the ‘setup’ and ‘go’ buttons. The ‘setup’ button initialises the model – here individuals (and their environment) are created, the ‘go’ button runs the model. This button is set to continue running the model until a ‘stop-command’ is reached in the code (e.g. if max-years is reached, or if there are no more individuals left). Alternatively there is a ‘go-once’ button, which allows you to run the model on step at a time. Run the model with its initial settings to run the ‘baseline model’ of Goedegebuure et al. (2018).

Under the ‘setup and general model settings and outcomes’ heading on the interface, there are five inputs to the model which can be easily adjusted. The starting population can be modified to increase or decrease the initial population modelled. The time the model runs for (in modelled years) can be set in ‘max-years’. This can be coupled with the run in period ‘clear-plots’ which clears plots after a set time period (years). The parameter ‘cv’ sets the individual variability. The parameter ‘f_scaled’ sets the functional response f for individuals; this is equal to the initial food availability and can be used to easily run simple food-related scenarios. In the model this is converted to effective food availability, which takes into account competition between the individuals in the population.


You can speed up the program by deactivating the "view updates" option on the Interace tab.


A simple method of getting model results from NetLogo is through immediate plotting on the interface. Plots can be in the form of graphs, histograms, or scatterplots. The plots are set up in the code (see the NetLogo manual; Plotting), and are updated in the very last procedure of each time-step. Output from the model can be exported as either image (.png file, for plots or the interface) or ‘comma-separated values’ file (.csv for plots and the whole model ‘world’). This can be done manually from the interface (right-click, ‘export…’) or through a line in the code (see the NetLogo manual; ‘export-’). It should be noted however, that when a filename already exists, it will be over-written. This can be avoided by creating unique names for each of the files which include the current date, for example.

An alternative method for collecting the model outputs - and this can be done for numerous model runs - is through the ‘BehaviourSpace’ option built in under ‘Tools’ in the model. This creates a popup where you can run multiple scenarios. The number of runs are adjusted through editing of the scenario and changing the number of repetitions. The results are automatically exported to a .csv file of your choosing, with the properties entered under ‘Measure runs using these reporters’. For a detailed explanation of BehaviourSpace, please see the NetLogo handbook at and select the BehaviourSpace link of the left of the page, under Features.

## References highlighted in model code
Carrick, R., S. Csordas, S. E. Ingham, and K. Keith. 1962. Studies on the southern elephant seal, Mirounga leonina (L.). III. The annual cycle in relation to age and sex. Wildlife Research 7:119-160.

Desprez, M., R. Harcourt, M. A. Hindell, S. Cubaynes, O. Gimenez, and C. R. McMahon. 2014. Age-specific cost of first reproduction in female southern elephant seals. Biology Letters 10:20140264.

Fedak, M., P. Lovell, and B. McConnell. 1996. MAMVIS: A marine mammal behaviour visualization system. The Journal of Visualization and Computer Animation 7:141-147.

Grimm, V., U. Berger, F. Bastiansen, S. Eliassen, V. Ginot, J. Giske, J. Goss-Custard, T. Grand, S. K. Heinz, and G. Huse. 2006. A standard protocol for describing individual-based and agent-based models. Ecological Modelling 198:115-126.

Grimm, V., U. Berger, D. L. DeAngelis, J. G. Polhill, J. Giske, and S. F. Railsback. 2010. The ODD protocol: a review and first update. Ecological Modelling 221:2760-2768.

Hindell, M., and D. Slip. 1997. The importance of being fat: maternal expenditure in the southern elephant seal Mirounga leonina. Pages 72-77 in Marine mammal research in the Southern Hemisphere.

Hindell, M. A., and G. J. Little. 1988. Longevity, fertility and philopatry of two female southern elephant seals (Mirounga leonina) at Macquarie Island. Marine Mammal Science 4:168-171.

Hindell, M. A., D. J. Slip, and H. R. Burton. 1994. Body mass loss of moulting female southern elephant seals, Mirounga leonina, at Macquarie Island. Polar Biology 14:275-278.

Kooijman, S. A. L. M. 2010a. Comments on Dynamic energy budget theory for metabolic
organisation. Cambridge University Press, New York.

Kooijman, S. A. L. M. 2010b. Dynamic energy budget theory for metabolic organisation. 3rd edition. Cambridge University Press, New York.
Laws, R. M. 1984. Antarctic ecology.

Martin, B. T., T. Jager, R. M. Nisbet, T. G. Preuss, and V. Grimm. 2013. Predicting population dynamics from the properties of individuals: a cross-level test of Dynamic Energy Budget theory. The American Naturalist 181:506-519.

Martin, B. T., E. I. Zimmer, V. Grimm, and T. Jager. 2012. Dynamic Energy Budget theory meets individual-based modelling: a generic and accessible implementation. Methods in Ecology and Evolution 3:445-449.

McMahon, C. R., H. R. Burton, and M. N. Bester. 2000. Weaning mass and the future survival of juvenile southern elephant seals, Mirounga leonina, at Macquarie Island. Antarctic Science 12:149-153.

McMahon, C. R., H. R. Burton, and M. N. Bester. 2003. A demographic comparison of two southern elephant seal populations. Journal of Animal Ecology 72:61-74.

Railsback, S. F., and V. Grimm. 2011. Agent-based and individual-based modeling: a practical introduction. Princeton University Press.

(back to the NetLogo User Community Models)