clearPatches: Clear 'world"s 'patches'

Description Usage Arguments Value Author(s) References See Also Examples

Description

Reset all patches values to NA.

Usage

1
2
3
4
5
6
7
clearPatches(world)

## S4 method for signature 'worldMatrix'
clearPatches(world)

## S4 method for signature 'worldArray'
clearPatches(world)

Arguments

world

WorldMatrix or worldArray object.

Value

WorldMatrix object with NA values for all patches.

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#clear-patches

Examples

1
2
3
4
5
6
7
8
w1 <- createWorld()
w1 <- NLset(world = w1, agents = patches(w1), val = runif(NLcount(patches(w1))))
w1Val <- of(world = w1, agents = patches(w1))
summary(w1Val)

w1 <- clearPatches(w1)
w1Val <- of(world = w1, agents = patches(w1))
summary(w1Val)

NetLogoR documentation built on July 10, 2021, 5:06 p.m.