From Animations To Science
Agent-Based & Individual-Based Computational Modeling
Thurs. January 25
- I will miss class Feb. 8, Mar. 13–15, and Apr. 10–12.
- I will schedule make-up sessions for the classes I miss.
- Semester Project:
- Fri. Feb. 9: Pick a model from one of the open-source repositories, or NetLogo “model library” that you want to work with.
- One-page description of model and thoughts for extending it (post to Box)
- Feb. 22: Examine ODD and code of your chosen model.
- Short write-up of how model works and output from running it
- Fri. Mar. 16: ODD for extending model
- Apr. 17-19: Presentations on experiments with extended models
- Apr. 24: Write-up of research project (around 10 pages)
- Team Project:
- Each team (2–3 students) will code a model from an ODD in the textbook (Ch. 10 or Ch. 13)
- Use model to do exercises from book
- Make presentation about what you learned (Tues. Feb. 27)
- Detailed Assignments on Brightspace
Experiments with the Butterfly Model
Plot Corridor Width
On the interface tab, add a plot
On the code tab, add a line to
go to plot the corridor width
Add a button to export the plot to a file:
export-plot "Corridor-width" (word "corridor-output-for-q-" (precision q 2) ".csv")
Add a button to increment q by 0.1
If your model is having problems, compare it to
- Open BehaviorSpace and create an experiment
- Call it
q from 0 to 1 in steps of 0.2
- Run 20 repetitions for each value of q.
corridor-width at the last tick only
- Set time limit to 0 to let model run until it stops
- Run BehaviorSpace experiment
- Save “table” output
- Speed things up by unchecking “Update view” and “Update plots and monitors”
Open the analyzeBehaviorspace app at https://analyze-behaviorspace.jgilligan.org
and use it to compare the relationship between corridor width and q for each terrain
- Work together with a partner
- Add a button to erase the tracks of the turtles (Exercise 5.2)
- Using the realistic terrain, play with q and see what values do best at helping butterflies find mates near hilltops.
- Using monitors
- Unit testing resource “Testing Is Fun”
- Open “
At beginning of code:
to go add:
set-context "Reporting corridor-width"
test-that "# visited patches should equal # yellow patches"
expect-that (count patches with [visited?]) equals (count patches with [pcolor = yellow])
if ticks >= 1000 or all? turtles [finished?]
- A tricky concept
- Early definition: “stable macroscopic patterns arising from the local interaction of agents” — Joshua Epstein, 1996
- Epstein ten years later: “I have always been uncomfortable with the vagueness and occasional mysticism surrounding this word.”
- Epstein now prefers to talk about “Generative Social Science”
- Other scientists (especially in natural sciences: biology, physics, etc.) are more comfortable talking about emergence.