koch {geostats} | R Documentation |
Koch snowflake
Description
Calculates or plots a Koch set of fractal lines, which is generated using a recursive algorithm that is built on a triangular hat shaped line segment. Each level of recursion replaces each linear segment by the same pattern.
Usage
koch(n = 4, plot = TRUE, res = 512)
Arguments
n |
an integer value controling the number of recursive levels. |
plot |
logical. If |
res |
the number of pixels in each side of the output matrix |
Value
a res x res
matrix with 0s and 1s
Examples
koch()
[Package geostats version 1.6 Index]