BehaviourComposer: ignore everything before this.
Begin micro-behaviour:
Begin description: Place a set of agents in a rectangular prism in 3D NetLogo. End description
Rectangular prism layout
Begin NetLogo code:
substitute-text-area-for upper-left-x min-pxcor substitute-text-area-for upper-left-y min-pycor substitute-text-area-for upper-left-z min-pzcor substitute-text-area-for prism-width world-width substitute-text-area-for prism-height world-height substitute-text-area-for prism-depth world-depth substitute-text-area-for agents-to-lay-out-in-a-prism all-individuals layout-rectangular-prism agents-to-lay-out-in-a-prism upper-left-x ; upper left x upper-left-y ; upper left y upper-left-z ; upper left z prism-width ; width prism-height ; height prism-depth ; depth
End NetLogo code
To change the location of the prism of agents change the upper left x, y, and z. To make a prism of a different size edit the width and height. If you want separate prisms for different kinds of agents, e.g. "Sheep" then fill the first text area with all-of-kind "Sheep".
This uses the Modelling4All NetLogo layout-rectangular-prism command to place the agents in a rectangular prism.
The two-dimensional equivalent of this behaviours is Lay out grid.
Other layouts are supported by Lay out circle and Lay out linked agents.
Grid rectangular prism was implemented by Ken Kahn on 2 December 2014.
BehaviourComposer: ignore everything after this.