sinData.Rd
n-1 points are drawn from a normal distribution with mean=0, sd=1, the points in the final direction are calculated as the sine of the values of direction n-1 with additional jittering controled by the jitter factor f.
sinData(n, p, f = 1)
sample points in tibble format
sinData(4, 100)
#> New names:
#> • `` -> `...1`
#> • `` -> `...2`
#> • `` -> `...3`
#> • `` -> `...4`
#> # A tibble: 100 × 4
#> ...1 ...2 ...3 ...4
#> <dbl> <dbl> <dbl> <dbl>
#> 1 1.03 0.257 0.708 0.650
#> 2 0.317 -2.15 -0.480 -0.462
#> 3 -1.11 0.690 -0.317 -0.311
#> 4 0.621 -1.77 0.510 0.489
#> 5 1.81 0.546 -0.266 -0.263
#> 6 1.11 0.0189 0.636 0.594
#> 7 0.465 -0.749 -1.01 -0.849
#> 8 -1.07 -0.794 0.932 0.803
#> 9 0.256 0.301 -0.651 -0.606
#> 10 -0.777 0.0547 0.436 0.422
#> # ℹ 90 more rows
sinData(2, 100, 200)
#> New names:
#> • `` -> `...1`
#> • `` -> `...2`
#> # A tibble: 100 × 2
#> ...1 ...2
#> <dbl> <dbl>
#> 1 0.0831 0.0527
#> 2 -1.89 -0.955
#> 3 1.06 0.871
#> 4 0.613 0.583
#> 5 0.590 0.542
#> 6 -0.0665 -0.0430
#> 7 -0.608 -0.599
#> 8 0.947 0.787
#> 9 0.393 0.396
#> 10 -0.385 -0.413
#> # ℹ 90 more rows