left {NetLogoR} | R Documentation |
Rotate to the left
Description
Rotate the turtles
's headings to the left of angle
degrees.
Usage
left(turtles, angle)
## S4 method for signature 'agentMatrix,numeric'
left(turtles, angle)
Arguments
turtles |
|
angle |
Numeric. Vector of angles in degrees by which to rotate the |
Details
If a given angle
value is negative, then the turtle
rotates to the right.
Value
AgentMatrix
representing the turtles
with updated heading
values.
Author(s)
Sarah Bauduin
References
Wilensky, U. 1999. NetLogo. http://ccl.northwestern.edu/netlogo/. Center for Connected Learning and Computer-Based Modeling, Northwestern University. Evanston, IL.
See Also
https://ccl.northwestern.edu/netlogo/docs/dictionary.html#left
Examples
w1 <- createWorld(minPxcor = 0, maxPxcor = 4, minPycor = 0, maxPycor = 4)
t1 <- createTurtles(n = 10, world = w1)
of(agents = t1, var = "heading")
t1 <- left(turtles = t1, angle = 180)
of(agents = t1, var = "heading")
[Package NetLogoR version 1.0.5 Index]