Description Usage Arguments Examples
project_ball
computes the Euclidean projection of a point onto a ball.
1 | project_ball(x, cnt, r)
|
x |
Point to project |
r |
Radius of the sphere |
center |
Center of the sphere |
1 2 3 4 5 6 | set.seed(12345)
p <- 3
cnt <- rnorm(p)
r <- runif(1)
x <- rnorm(p)
y <- project_ball(x,cnt,r)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.