gen_checkerboard {ambient} | R Documentation |
Generate a checkerboard pattern
Description
This generator supplies 0 or 1 value depending on the provided coordinates
position on a checkerboard. The frequency
determines the number of squares
per unit.
Usage
gen_checkerboard(x, y = NULL, z = NULL, t = NULL, frequency = 1, ...)
Arguments
x , y , z , t |
The coordinates to get pattern from |
frequency |
The frequency of the generator |
... |
ignored |
Value
A numeric vector
See Also
Other Pattern generators:
gen_spheres()
,
gen_waves()
Examples
grid <- long_grid(seq(1, 10, length.out = 1000), seq(1, 10, length.out = 1000))
grid$chess <- gen_checkerboard(grid$x, grid$y)
plot(grid, chess)
[Package ambient version 1.0.2 Index]