This function draws lissajous curves with points connected via a k-nearest neighbor approach.

canvas_lissajous(
  colors,
  background = "#000000",
  iterations = 2,
  neighbors = 50,
  noise = FALSE
)

Arguments

colors

a string or character vector specifying the color(s) used for the artwork.

background

a character specifying the color used for the background.

iterations

a positive integer specifying the number of iterations of the algorithm.

neighbors

a positive integer specifying the number of neighbors a block considers when drawing the connections.

noise

logical. Whether to add perlin noise to the coordinates of the nodes.

Value

A ggplot object containing the artwork.

See also

colorPalette

Author

Koen Derks, koen-derks@hotmail.com

Examples

# \donttest{
set.seed(13)

# Simple example
canvas_lissajous(colors = colorPalette("blossom"))

# }