50% off | Unlimited Data & AI Learning
Get 50% off unlimited learning

gasper (version 1.1.4)

swissroll: Swiss roll graph generation

Description

Map the square [0,1]2 in swiss roll for all x,y in [0,1]2, set Sx=π(b2a2)x+a2) Sy=π(b2a2)y/2

Usage

swissroll(N = 500, seed = NULL, a = 1, b = 4)

Value

N x 3 array for 3d points.

Arguments

N

Number of points drawn.

seed

Optionally specify a RNG seed (for reproducible experiments).

a, b

Shape parameters.

See Also

adjacency_mat

Examples

Run this code
pts <- swissroll(N=500, seed=0, a=1, b=4)

Run the code above in your browser using DataLab