clearPatches: Clear 'world"s 'patches'

clearPatchesR Documentation

Clear world's patches

Description

Reset all patches values to NA.

Usage

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

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)


PredictiveEcology/NetLogoR documentation built on Jan. 31, 2024, 9:31 p.m.