CodeExamples - gama-platform/gama GitHub Wiki
Code Examples
This page references a number of code examples with a capture of it running in GAMA.
Data
Data Importation
- 3D shapefile loading.gaml, 1 experiment, 3D
- ASC File Import.gaml - ESRI ASCII to grid model, 1 experiment, 2D
- Contour Lines.gaml - Contour Lines Import, 1 experiment, 3D
- DXF File Import.gaml, 1 experiment, 2D
- GEOJSON File Import, 1 experiment, 3D
- Grid DEM.gaml - ASCII File to DEM Representation, 3 experiments, 3D
- Image Vectorisation.gaml, 1 experiment, 2D
- OSM File Import.gaml - OSM file to Agents, 2 experiments, 2D
- SHP Import.gaml - Shapefile to Agents, 1 experiment, 3D
Modelling
Spatial Topology
- Agent Movement
- Continuous Field of Vision.gaml, 1 experiment, 2D
- Follow Path.gaml - Movement of an agent on different paths, 1 experiment, 2D
- Goto Directed Graph.gaml - Directed Graph Model, 1 experiment, 2D
- Goto Grid.gaml - Movement on a Grid of Cells, 1 experiment, 2D
- Goto Grid Weights.gaml - Movement on a Grid of Cells, 1 experiment, 2D
- Goto Polygon.gaml, 1 experiment, 2D
- Moving3D.gaml, 5 experiments, 3D
- Wander on Graph, 1 experiment, 2D
- Fields
- Accessing Fields.gaml, 1 experiment, 3D
- Graphs
- 3D Graph - 3D_Graph, 2 experiments, 3D
- Classic Graph Generation.gaml - Graph Generation, 1 experiment, 2D
- Graph Building from Agents.gaml - Graph Generation using Agents, 1 experiment, 2D
- Strahler.gaml - Strahler, 1 experiment, 2D
- Grids
- Weighted Shortest Path on Grid.gaml, Computation of the shortest path on a Grid of Cells, 1 experiment, 2D
Toy Models
Ants (Foraging and Sorting)
- Ants Foraging.gaml, 3 experiments, 2D
Art
- Trees and Seasons, 3 experiments, 3D
- Mondrian City.gaml, 1 experiment, 2D
Boids
- Boids 3D Motion.gaml, 1 experiment, 3D
Bubble Sort
- Bubble Sort 3D.gaml, 1 experiment, 3D
Epidemiology
- SIR (ABM vs EBM).gaml, 1 experiment, 2D
Evacuation
- Continuous Move.gaml, 1 experiment, 3D
Flood Simulation
- Hydrological Model.gaml, 1 experiment, 3D
K Neareast Neighbours
- knn.gaml, 1 experiment, 2D
Learning
- Mas KMeans.gaml, 2 experiments, 2D, 3D
Life
- Life.gaml, 1 experiment, 2D
Multi-level Data Analysis
- Graph from Bug (Mirror Graph).gaml, 1 experiment, 3D
- MODAVI.gaml, 1 experiment, 2D
Predator Prey
- Lotka-Volterra (Influence of Integration Step).gaml, 1 experiment, 2D, Charts
Segregation (Schelling)
- Segregation (Agents).gaml, 1 experiment, 2D
Soccer
- Soccer.gaml, 1 experiment, 2D
Sugarscape
- Sugarscape.gaml, 1 experiment, 2D
Traffic
- Netlogo Traffic Model-2 Roads.gaml, 1 experiment, 2D
- Traffic and pollution.gaml, 1 experiment, 3D
Waterflow
- Waterflow Field Elevation.gaml, 1 experiment, 3D
Visualisation and User Interaction
Visualisation
- 3D Visualisation
- Moving 3D Object.gaml, 1 experiment, 3D
- Charts
- Series.gaml, 1 experiment, 2D, charts
- DEM Generator.gaml, 1 experiment, 3D
Plugin Models
BDI Architecture
- CityEscape_BDI_Emotions.gaml, 1 experiment, 2D
Diffusion Statement
- Anisotropic Diffusion (Simple, Field).gaml, 1 experiment, 3D
Driving Skill
- Advanced Models
- Drive Random.gaml, 2 experiments, 2D
- Simple Intersection.gaml, 1 experiment, 2D
- Simple model
- Simple Traffic Model, 1 experiment, 2D
Images
- Casting Images.gaml, 1 experiment, 2D, 3D
- Image Manipulation.gaml, 1 experiment, 2D
Ordinary Differential Equations
- Examples
- Stochastic Differential Equation.gaml, 1 experiment, 2D, charts
- For Advanced Users
- SIR (Split in Agents, Multiple Strains).gaml, 1 experiment, 2D, charts
Pedestrian Skill
- Complex environment-walk.gaml, 1 experiment, 2D
- Generate pedestrian paths.gaml, 1 experiment, 2D
- Simple environment-walk_to.gaml, 3 experiments, 2D
Physics Engine
- Eroding Volcano.gaml, 1 experiment, 3D
- Flow on Terrain.gaml, 1 experiment, 3D
- Hello World.gaml, 1 experiment, 3D
- Play Pool.gaml, 1 experiment, 3D
- Stairs.gaml, 1 experiment, 3D