Turtle Commands

Print Version of Turtle Commands

A | B | C | D | E | F | G | H | I | J / K | L | M | N | O | P / Q | R | S | T / U | V | W | X | Y / Z

These are commands that turtles can run, either from Turtle Procedures, or through and ask-turtles statement in the Observer Procedures.

A
abs

acos

alive?

alive?-of

and

asin

ask-breed-with

ask-list-of-turtles

ask-patch-at

ask-turtle

atan

average-of-breed

average-of-breed-with

average-of-list

average-of-patches

average-of-patches-with

average-of-turtles

average-of-turtles-with

B
back (bk)

bf (butfirst)

bitand

bitnot

bitor

bitxor

bk (back)

bl (butlast)

black

blue

breed

breed-at

breed-of

breed-towards

breeds

brown

butfirst (bf)

butlast (bl)

C
case

cc (clear-command-center)

clear-command-center (cc)

clear-plot (clearplot)

clearplot (clear-plot)

color

color-at

color-of

color-towards

copy-list

cos

count-breed

count-breed-at

count-breed-here

count-breed-towards

count-breed-with

count-color

count-color-range

count-patches

count-patches-with

count-pc

count-pc-range

count-plot-pens

count-turtles

count-turtles-at

count-turtles-here

count-turtles-towards

count-turtles-with

cyan

D
die

distance

distance-nowrap

div

dolist

dotimes

dx

dy

E
e

every

exp

F
fd (forward)

first

forward (fd)

fput

G
get-random-seed

globals

grab

grabbed?

gray (grey)

green

grey (gray)

H
hatch

heading

heading-at

heading-of

heading-towards

hide-turtle (hideturtle ht)

hideturtle (hide-turtle) (ht)

home

ht (hide-turtle hideturtle)

I
if

ifelse

ignore

insert

int

item

J / K
jump

kill

L
last

leap

left (lt)

length

let

lime

list

list-of-breed

list-of-breed-at

list-of-breed-here

list-of-breed-towards

list-of-turtles

list-of-turtles-at

list-of-turtles-here

list-of-turtles-towards

list-of-turtles-with

list?

ln

log

loop

lput

lt (left)

M
magenta

make-list

max (maximum)

max-of-breed

max-of-breed-with

max-of-list

max-of-patches

max-of-patches-with

max-of-turtles

max-of-turtles-with

maximum (max)

maxnum

median-of-breed

median-of-breed-with

median-of-list

median-of-patches

median-of-patches-with

median-of-turtles

median-of-turtles-with

member?

min (minimum)

min-of-breed

min-of-breed-with

min-of-list

min-of-patches

min-of-patches-with

min-of-turtles

min-of-turtles-with

minimum (min)

minnum

mod

mode-of-breed

mode-of-list

mode-of-patches

mode-of-patches-with

mode-of-turtles

mode-of-turtles-with

mouse-down?

mouse-xcor

mouse-ycor

myself

N
nobody

not

number?

O
one-of-breed

one-of-breed-at

one-of-breed-at-with

one-of-breed-here

one-of-breed-here-with

one-of-breed-towards

one-of-breed-towards-with

one-of-breed-with

one-of-turtles

one-of-turtles-at

one-of-turtles-at-with

one-of-turtles-here

one-of-turtles-here-with

one-of-turtles-towards

one-of-turtles-towards-with

one-of-turtles-with

or

orange

output

P / Q
partner

partners

patchcolor (pc)

pc (patchcolor)

pc-ahead (pc-ahead-one-step)

pc-ahead-one-patch

pc-ahead-one-step (pc-ahead)

pc-at

pc-towards

pd (pendown)

pendown (pd)

pendown?

pendown?-at

pendown?-of

pendown?-towards

penup (pu)

pi

pick

pink

plot

plot-grid-off

plot-grid-on

plot-grid?

plot-title

plot-xlabel

plot-xmax

plot-xmin

plot-ylabel

plot-ymax

plot-ymin

plotid

plotxy

position

pp

ppc

ppd

ppreset

ppu

ppxcor

ppycor

print

print-status

pu (penup)

purple

R
random

random-gaussian

red

remove

remove-element

repeat

reset-timer (resett)

resett (reset-timer)

reverse

right (rt)

round

rt (right)

S
scale-color

screen-half-height

screen-half-width

screen-height

screen-width

sdev-of-breed

sdev-of-breed-with

sdev-of-list

sdev-of-patches

sdev-of-patches-with

sdev-of-turtles

sdev-of-turtles-with

se (sentence)

sentence (se)

set

setbreed

setbreed-at

setbreed-of

setbreed-towards

setc (setcolor)

setc-at

setc-of

setc-towards

setcolor (setc)

seth (setheading)

seth-at

seth-of

seth-towards

setheading (seth)

setitem

setpatchcolor (setpc)

setpc (setpatchcolor)

setpendown?-at

setpendown?-of

setpendown?-towards

setplot-bar-width

setplot-title

setplot-xlabel

setplot-xmax

setplot-xmin

setplot-xrange

setplot-ylabel

setplot-ymax

setplot-ymin

setplot-yrange

setppc

setshape

setshape-at

setshape-of

setshape-towards

setshown?-at

setshown?-of

setshown?-towards

setslidervar

setvariable

setvariable-at

setvariable-of

setvariable-towards

setx (setxcor)

setx-at (setxcor-at)

setx-of (setxcor-of)

setx-towards (setxcor-towards)

setxcor (setx)

setxcor-at (setx-at)

setxcor-of (setx-of)

setxcor-towards (setx-towards)

setxy

setxy-at

setxy-of

setxy-towards

sety (setycor)

sety-at (setycor-at)

sety-of (setycor-of)

sety-towards (setycor-towards)

setycor (sety)

setycor-at (sety-at)

setycor-of (sety-of)

setycor-towards (sety-towards)

shape

shape-at

shape-of

shape-towards

show

show-turtle (showturtle st)

shown?

shown?-at

shown?-of

shown?-towards

showturtle (show-turtle) (st)

sin

sky

sort-num-list

sqrt

st (show-turtle showturtle)

stamp

stamp-at

stamp-towards

step

stop

stopall

sublist

sum-of-breed

sum-of-breed-with

sum-of-list

sum-of-patches

sum-of-patches-with

sum-of-turtles

sum-of-turtles-with

T / U
tan

timer

to

to-delimited-string

to-list

to-string

towards

towards-nowrap

turquoise

turtles-own

type

V
variable

variable-at

variable-of

variable-towards

variance-of-breed

variance-of-breed-with

variance-of-list

variance-of-patches

variance-of-patches-with

variance-of-turtles

variance-of-turtles-with

view-plot

W
wait

wait-until

white

who

who-max-of-breed

who-max-of-breed-with

who-max-of-turtles

who-max-of-turtles-with

who-min-of-breed

who-min-of-breed-with

who-min-of-turtles

who-min-of-turtles-with

word?

X
xcor

xcor-at

xcor-of

xcor-towards

xor

Y / Z
ycor

ycor-at

ycor-of

ycor-towards

yellow