Presentation is loading. Please wait.

Presentation is loading. Please wait.

Hands-On given by Gabriel Wurzer and Wolfgang E. Lorenz

Similar presentations


Presentation on theme: "Hands-On given by Gabriel Wurzer and Wolfgang E. Lorenz"— Presentation transcript:

1 Hands-On given by Gabriel Wurzer and Wolfgang E. Lorenz

2 Previously: hospital-1 example with interaction
hospital-1.zip on lecture site

3 Demographics The World Patches other Turtles Turtle initial population
development The World consisting of Patches holding population hosting other Turtles of breed hospital Turtle of breed hospital with constant capacity (in units of population) with constant radius (in patches) with constant radius and capacity compute radius compute capacity check adequacy

4 Characterization Uses statistics (import as (list ..) or (list (list …) …) to generate population May also use absolute number of people per year (preferred) May calculate in excel, then transfer just the needed column to Netlogo (preferred) Maps to be used have to be tweaked (e.g. import three kinds of patches [RED, GREEN, BLUE] into NetLogo, clean the patch errors in NetLogo, export again)

5 hospital-2 example (also on lecture site)
Zone 2 Zone 1 plots (new!) Zone 0

6 Creating Plots created in the user interface using
give a descriptive name set x and y labels and min/max set „show legend“ one plot pen default is already created can create new ones with „Create“ can set pen mode to Line, Bar, Point

7 Using Plots choose plot with set-current-plot „plot-name“
choose pen with set-current-plot-pen „plot-pen-name“ draw using plotxy x-value y-value

8 Movement The World Patches other Turtles Turtle tools for interacting
initial population demographic development The World consisting of Patches holding population hosting other Turtles of breed hospital Turtle of breed hospital tools for interacting with constant capacity (in units of population) with constant radius (in patches) with constant radius and capacity compute radius compute capacity check adequacy

9 Movement Moving through world, i.e. agents = patients or hospitals
Prediction of „interesting“ parameters, here: expected treatments per hospital over time, and visualization of these Technically: setup setup hospitals setup population go demographics generate n patients requiring treatment: choose a hospital for each patient move patients to hospital (using a loop)

10 Loop? while there are still patients that need treatment (condition)
ask these patients if distance to hospital > 1 then move closer towards hospital else hospital was reached: increase treatments remove patient from simulation loops are similar to a „go“ button, but not the same. why do we need them (guess?)

11 So far… The button repeats code until it is depressed unpressed again.
There is no „go within go“, however. Repeating things inside go therefore has to take a while loop: to go create-patients […] while treatment is needed move patients to hospitals ] end Usage: while [ condition ] [ run these commands ]

12 hospital-3 (on lecture site)
Try these

13 Hands-On: Outcome from work in lecture
AgentsFindingHospital on lecture site

14 Thank you !


Download ppt "Hands-On given by Gabriel Wurzer and Wolfgang E. Lorenz"

Similar presentations


Ads by Google