# sampling on the first orthant:
sims <-
runif_on_spherePatch(100, phi1 = 0, phi2 = pi/2, theta1 = 0, theta2 = pi/2)
if (FALSE) {
library(rgl)
spheres3d(0, 0, 0, color = "red", alpha = 0.5)
points3d(sims)}
Run the code above in your browser using DataLab