ReLogo Primitives ver. 2.5

Turtle   Utilities   Patch   Observer   Link  

Turtle

Motion Primitives Spatial primitives Turtle creation/destruction primitives Rotation primitives Turtle property primitives Ask primitives Turtle-centric primitives Patch-centric primitives Link-centric primitives AgentSet/Collection primitives World primitives Query primitives Miscellaneous primitives Pen primitives Visibility primitives
back(Number)
bk(Number)
canMoveQ(Number)
downhill(String)
downhill4(String)
fd(Number)
forward(Number)
home()
jump(Number)
moveTo(Patch)
moveTo(Turtle)
setXcor(Number)
setxy(Number,Number)
setYcor(Number)
uphill(String)
uphill4(String)
distance(Patch)
distance(Turtle)
distancexy(Number,Number)
dx()
dy()
getXcor()
getYcor()
getPxcor()
getPycor()
inCone(Collection,Number,Number)
inRadius(Collection,Number)
die()
hatch(Number)
hatch(Number,Closure)
hatch(Number,Closure,String)
hatch(Number,Closure,Class)
face(Patch)
face(Turtle)
facexy(Number,Number)
left(Number)
lt(Number)
right(Number)
rt(Number)
towards(Patch)
towards(Turtle)
towardsxy(Number,Number)
getColor()
setColor(Number)
getHeading()
setHeading(Number)
getLabel()
setLabel(Object)
getLabelColor()
setLabelColor(Number)
getPcolor()
setPcolor(Number)
getPenMode()
setPenMode(Number)
getPenSize()
setPenSize(Number)
getPxcor()
getPycor()
getShape()
setShape(String)
getSize()
setSize(Number)
getWho()
getXcor()
setXcor(Number)
getYcor()
setYcor(Number)
ask(AgentSet<? extends ReLogoAgent>,Closure)
ask(Collection<? extends ReLogoAgent>,Closure)
ask(Link,Closure)
ask(Patch,Closure)
ask(Turtle,Closure)
myself()
turtle(Number)
turtles()
turtlesAt(Number,Number)
turtlesHere()
turtlesOn(Collection)
turtlesOn(Patch)
turtlesOn(Turtle)
downhill(String)
downhill4(String)
uphill(String)
uphill4(String)
neighbors()
neighbors(int)
neighbors(int,int)
neighbors4()
neighbors4(int)
neighbors4(int,int)
patch(Number,Number)
patchAhead(Number)
patchAt(Number,Number)
patchAtHeadingAndDistance(Number,Number)
patches()
patchHere()
patchLeftAndAhead(Number,Number)
patchRightAndAhead(Number,Number)
allLinks()
allMyInLinks()
allMyLinks()
allMyOutLinks()
createLinkFrom(Turtle)
createLinkFrom(Turtle,Closure)
createLinksFrom(Collection<? extends Turtle>,Closure)
createLinksFrom(Collection<? extends Turtle>)
createLinksFrom(Collection<? extends Turtle>,Closure)
createLinksTo(Collection<? extends Turtle>,Closure)
createLinksTo(Collection<? extends Turtle>)
createLinksTo(Collection<? extends Turtle>,Closure)
createLinksWith(Collection<? extends Turtle>,Closure)
createLinksWith(Collection<? extends Turtle>)
createLinksWith(Collection<? extends Turtle>,Closure)
createLinkTo(Turtle)
createLinkTo(Turtle,Closure)
createLinkWith(Turtle)
createLinkWith(Turtle,Closure)
inLinkFrom(Turtle)
inLinkNeighborQ(Turtle)
inLinkNeighbors()
link(Number,Number)
link(Turtle,Turtle)
linkNeighborQ(Turtle)
linkNeighbors()
links()
linkWith(Turtle)
myInLinks()
myLinks()
myOutLinks()
otherEnd()
outLinkNeighborQ(Turtle)
outLinkNeighbors()
outLinkTo(Turtle)
allQ(Collection,Closure)
maxNOf(int,Collection<? extends ReLogoAgent>,Closure)
maxOneOf(Collection<? extends ReLogoAgent>,Closure)
minNOf(int,Collection<? extends ReLogoAgent>,Closure)
minOneOf(Collection<? extends ReLogoAgent>,Closure)
inCone(Collection,Number,Number)
inRadius(Collection,Number)
other(Collection)
getMaxPxcor()
getMaxPycor()
getMinPxcor()
getMinPycor()
randomPxcor()
randomPycor()
randomXcor()
randomYcor()
worldHeight()
worldWidth()
allQ(Collection,Closure)
canMoveQ(Number)
isHiddenQ()
inLinkNeighborQ(Turtle)
linkNeighborQ(Turtle)
outLinkNeighborQ(Turtle)
fileShow(Object)
run(String)
show(Object)
self()
runresult(String)
getPenMode()
getPenSize()
pd()
pe()
penDown()
penErase()
penUp()
pu()
setPenMode(Number)
setPenSize(Number)
hideTurtle()
ht()
isHiddenQ()
setHiddenQ(boolean)
showTurtle()
st()

Utilities

Color primitives String primitives Collection/List primitives AgentSet primitives Math primitives Query primitives Random number primitives Time and ticks primitives Input/Output primitives Miscellaneous primitives
black()
blue()
brown()
cyan()
gray()
green()
lime()
magenta()
orange()
pink()
red()
sky()
turquoise()
violet()
white()
yellow()
baseColors()
scaleColor(Number,Number,Number,Number)
shadeOfQ(Number,Number)
wrapColor(Number)
hsb(Number,Number,Number)
butFirst(String)
butLast(String)
capitalize(String)
emptyQ(String)
first(String)
item(int,String)
last(String)
length(String)
memberQ(String,String)
position(String,String)
remove(String,String)
removeItem(int,String)
replaceItem(int,String,String)
reverse(String)
substring(String,int,int)
word(Object...)
anyQ(Collection)
butFirst(List<E>)
butLast(List<E>)
count(Collection)
emptyQ(Collection)
filter(Closure,Collection<E>)
first(List<E>)
flatten(Collection)
foreach(Closure,List...)
foreach(Closure,Collection)
fput(Object,List)
item(int,List<E>)
last(List<E>)
length(Collection)
list(Object...)
lput(Object,List)
map(Closure,List...)
map(Closure,Collection)
max(Collection)
mean(Collection)
median(Collection)
memberQ(Object,Collection)
min(Collection)
modes(Collection)
nOf(int,Collection<E>)
nValues(int,Closure)
oneOf(Collection<X>)
position(Object,List)
reduce(Closure,List<E>)
remove(Object,Collection<E>)
removeDuplicates(List<E>)
removeItem(int,List<E>)
replaceItem(int,List,Object)
reverse(List<E>)
sentence(Object...)
shuffle(List<E>)
sort(List)
sortBy(Closure,Collection<E>)
standardDeviation(Collection)
sublist(List<E>,int,int)
sum(Collection)
variance(Collection)
linkSet(Object...)
nOf(int,AgentSet<E>)
noLinks()
noPatches()
noTurtles()
patchSet(Object...)
sort(AgentSet)
turtleSet(Object...)
abs(Number)
acos(Number)
asin(Number)
atan(Number,Number)
ceiling(Number)
cos(Number)
e()
floor(Number)
intPart(Number)
ln(Number)
log(Number,Number)
mod(Number,Number)
modes(Collection)
pi()
precision(BigDecimal,int)
remainder(Number,Number)
round(Number)
sin(Number)
sqrt(Number)
standardDeviation(Collection)
sum(Collection)
tan(Number)
variance(Collection)
isAgentQ(Object)
isAgentSetQ(Object)
isBooleanQ(Object)
isDirectedLinkQ(Object)
isLinkQ(Object)
isLinkSetQ(Object)
isListQ(Object)
isNumberQ(Object)
isPatchQ(Object)
isPatchSetQ(Object)
isStringQ(Object)
isTurtleQ(Object)
isTurtleSetQ(Object)
isUndirectedLinkQ(Object)
random(Number)
randomExponential(Number)
randomFloat(Number)
randomGamma(Number,Number)
randomNormal(Number,Number)
randomPoisson(Number)
newSeed()
randomSeed(int)
dateAndTime()
pause()
resetTicks()
resetTimer()
stop()
tick()
tickAdvance(Number)
ticks()
timer()
wait(Number)
beep()
fileAtEndQ()
fileClose()
fileCloseAll()
fileDelete(String)
fileExistsQ(String)
fileFlush()
fileOpen(String)
filePrint(Object)
fileRead()
fileReadCharacters(int)
fileReadLine()
fileType(Object)
fileWrite(Object)
flushFileSinks()
print(Object)
setCurrentDirectory(String)
type(Object)
userDirectory()
userFile()
userInput(Object)
userMessage(Object)
userNewFile()
userOneOf(Object,Object...)
userYesOrNoQ(Object)
write(Object)
ifelseValue(Closure,Closure,Closure)
readFromString(String)
repeat(Number,Closure)
subtractHeadings(double,double)

Patch

Spatial primitives Patch property primitives AgentSet/Collection primitives Ask primitives Turtle-centric primitives Patch-centric primitives Link-centric primitives World primitives Query primitives Miscellaneous primitives
distance(Patch)
distance(Turtle)
distancexy(Number,Number)
getPxcor()
getPycor()
inRadius(Collection,Number)
neighbors()
neighbors(int)
neighbors(int,int)
neighbors4()
neighbors4(int)
neighbors4(int,int)
getPcolor()
setPcolor(double)
getPlabel()
setPlabel(Object)
getPlabelColor()
setPlabelColor(Number)
setToDefault()
maxNOf(int,Collection<? extends ReLogoAgent>,Closure)
maxOneOf(Collection<? extends ReLogoAgent>,Closure)
minNOf(int,Collection<? extends ReLogoAgent>,Closure)
minOneOf(Collection<? extends ReLogoAgent>,Closure)
other(Collection)
ask(AgentSet<? extends ReLogoAgent>,Closure)
ask(Link,Closure)
ask(Collection<? extends ReLogoAgent>,Closure)
ask(Patch,Closure)
ask(Turtle,Closure)
myself()
sprout(Number)
sprout(Number,Closure)
sprout(Number,Closure,Class)
sprout(Number,Closure,String)
turtle(Number)
turtles()
turtlesAt(Number,Number)
turtlesHere()
turtlesOn(Collection)
turtlesOn(Patch)
turtlesOn(Turtle)
patch(Number,Number)
patchAt(Number,Number)
patchAtHeadingAndDistance(Number,Number)
patches()
allLinks()
link(Number,Number)
link(Turtle,Turtle)
links()
getMaxPxcor()
getMaxPycor()
getMinPxcor()
getMinPycor()
randomPxcor()
randomPycor()
randomXcor()
randomYcor()
worldHeight()
worldWidth()
allQ(Collection,Closure)
fileShow(Object)
run(String)
runresult(String)
self()
show(Object)

Observer

Ask primitives Turtle-centric primitives Turtle creation primitives Patch-centric primitives Diffusible primitives Clear primitives World primitives Link-centric primitives AgentSet/Collection primitives Miscellaneous primitives
ask(AgentSet<? extends ReLogoAgent>,Closure)
ask(Link,Closure)
ask(Collection<? extends ReLogoAgent>,Closure)
ask(Patch,Closure)
ask(Turtle,Closure)
setDefaultShape(Class,String)
setDefaultShape(String,String)
turtle(Number)
turtles()
turtlesOn(Collection)
turtlesOn(Patch)
turtlesOn(Turtle)
createTurtles(int)
createTurtles(int,Closure)
createTurtles(int,Closure,Class)
createTurtles(int,Closure,String)
createTurtlesFromCSV(String)
createTurtlesFromCSV(String,Closure)
createTurtlesFromCSV(String,Class<E>)
createTurtlesFromCSV(String,Class<E>,Closure)
createTurtlesFromExcel(String)
createTurtlesFromExcel(String,Closure)
createTurtlesFromExcel(String,Class<E>)
createTurtlesFromExcel(String,Class<E>,Closure)
createTurtlesFromExcelWithSheet(String,String)
createTurtlesFromExcelWithSheet(String,String,Closure)
createTurtlesFromExcelWithSheet(String,String,Class<E>)
createTurtlesFromExcelWithSheet(String,String,Class<E>,Closure)
crt(int)
crt(int,Closure)
crt(int,Closure,Class)
crt(int,Closure,String)
createOrderedTurtles(int)
createOrderedTurtles(int,Closure)
createOrderedTurtles(int,Closure,Class)
createOrderedTurtles(int,Closure,String)
createOrderedTurtlesFromCSV(String)
createOrderedTurtlesFromCSV(String,Closure)
createOrderedTurtlesFromCSV(String,Class<E>)
createOrderedTurtlesFromCSV(String,Class<E>,Closure)
createOrderedTurtlesFromExcel(String)
createOrderedTurtlesFromExcel(String,Closure)
createOrderedTurtlesFromExcel(String,Class<E>)
createOrderedTurtlesFromExcel(String,Class<E>,Closure)
createOrderedTurtlesFromExcelWithSheet(String,String)
createOrderedTurtlesFromExcelWithSheet(String,String,Closure)
createOrderedTurtlesFromExcelWithSheet(String,String,Class<E>)
createOrderedTurtlesFromExcelWithSheet(String,String,Class<E>,Closure)
cro(int)
cro(int,Closure)
cro(int,Closure,Class)
cro(int,Closure,String)
patch(Number,Number)
patches()
diffuse(String,double)
diffuse4(String,double)
diffusibleAdd(String,Number)
diffusibleApply(String,DoubleFunction)
diffusibleDivide(String,Number)
diffusibleMultiply(String,Number)
diffusibleSubtract(String,Number)
clearAll()
ca()
clearLinks()
clearPatches()
cp()
clearTurtles()
ct()
getMaxPxcor()
getMaxPycor()
getMinPxcor()
getMinPycor()
randomPxcor()
randomPycor()
randomXcor()
randomYcor()
worldHeight()
worldWidth()
allLinks()
link(Number,Number)
link(Turtle,Turtle)
links()
maxNOf(int,Collection<? extends ReLogoAgent>,Closure)
maxOneOf(Collection<? extends ReLogoAgent>,Closure)
minNOf(int,Collection<? extends ReLogoAgent>,Closure)
minOneOf(Collection<? extends ReLogoAgent>,Closure)
allQ(Collection,Closure)
fileShow(Object)
registerModelParameterListener(String,Closure)
run(String)
runresult(String)
show(Object)

Link

Link property primitives AgentSet/Collection primitives Ask primitives Turtle-centric primitives Patch-centric primitives Link-centric primitives World primitives Tie primitives Visibility primitives Miscellaneous primitives
getColor()
setColor(Number)
getEnd1()
setEnd1(T)
getEnd2()
setEnd2(T)
getLabelColor()
setLabelColor(Number)
maxNOf(int,Collection<? extends ReLogoAgent>,Closure)
maxOneOf(Collection<? extends ReLogoAgent>,Closure)
minNOf(int,Collection<? extends ReLogoAgent>,Closure)
minOneOf(Collection<? extends ReLogoAgent>,Closure)
other(Collection)
ask(AgentSet<? extends ReLogoAgent>,Closure)
ask(Link,Closure)
ask(Collection<? extends ReLogoAgent>,Closure)
ask(Patch,Closure)
ask(Turtle,Closure)
myself()
otherEnd()
bothEnds()
turtle(Number)
turtles()
turtlesOn(Collection)
turtlesOn(Patch)
turtlesOn(Turtle)
patch(Number,Number)
patches()
allLinks()
die()
link(Number,Number)
link(Turtle,Turtle)
linkHeading()
linkLength()
links()
getMaxPxcor()
getMaxPycor()
getMinPxcor()
getMinPycor()
randomPxcor()
randomPycor()
randomXcor()
randomYcor()
worldHeight()
worldWidth()
tie()
setTieMode(String)
untie()
hideLink()
isHiddenQ()
showLink()
setHiddenQ(boolean)
allQ(Collection,Closure)
fileShow(Object)
self()
show(Object)
run(String)
runresult(String)