canvas_mandelbrot {aRtsy}R Documentation

Draw the Mandelbrot Set

Description

This function draws the Mandelbrot set on the canvas.

Usage

canvas_mandelbrot(colors, iterations = 100, zoom = 1, left = -1.7, right = -0.2,
                   bottom = -0.2999, top = 0.8001, resolution = 500)

Arguments

colors

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

iterations

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

zoom

a positive value specifying the amount of zoom to apply.

left

a value specifying the minimum location on the x-axis.

right

a value specifying the maximum location on the x-axis.

bottom

a value specifying the minimum location on the y-axis.

top

a value specifying the maximum location on the y-axis.

resolution

resolution of the artwork in pixels per row/column. Increasing the resolution increases the quality of the artwork but also increases the computation time exponentially.

Value

A ggplot object containing the artwork.

Author(s)

Koen Derks, koen-derks@hotmail.com

References

https://en.wikipedia.org/wiki/Mandelbrot_set

See Also

colorPalette

Examples


canvas_mandelbrot(colors = colorPalette("tuscany1"))



[Package aRtsy version 0.1.8 Index]