fractal_fern: Generate fractal fern data

Description Usage Arguments Examples

View source: R/fractal_fern.R

Description

Generates data for plotting a fractal fern and stores it in a data frame with (x, y) coordinates. Refer to the Wikipedia article for details.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
fractal_fern(
  n = 10000,
  a = c(0, 0.85, 0.2, -0.15),
  b = c(0, 0.04, -0.26, 0.28),
  c_ = c(0, -0.04, 0.23, 0.26),
  d = c(0.16, 0.85, 0.22, 0.24),
  e = c(0, 0, 0, 0),
  f = c(0, 1.6, 1.6, 0.44),
  p = c(0.01, 0.85, 0.07, 0.07)
)

Arguments

n

The number of points to generate

a

Coefficient vector of length 4

b

Coefficient vector of length 4

d

Coefficient vector of length 4

e

Coefficient vector of length 4

f

Coefficient vector of length 4

p

Probability vector of length 4

c

Coefficient vector of length 4

Examples

1

marcusvolz/mathart documentation built on May 24, 2021, 4:16 p.m.