search for: rotm

Displaying 1 result from an estimated 1 matches for "rotm".

Did you mean: rom
2011 Jan 31
1
rgl: draw multiple ellipsoids
...<- c("mesh3d","shape3d") norm <- sqrt(sphere$vb[1, ]^2 + sphere$vb[2, ]^2 + sphere$vb[3, ]^2) for (i in 1:3) sphere$vb[i, ] <- sphere$vb[i, ]/norm sphere$vb[4, ] <- 1 sphere$normals <- sphere$vb result <- scale3d(sphere, a,b,c) rotM <- euler(phi,theta,psi) result <- rotate3d(result,matrix=rotM) result <- translate3d(result, x,y,z) invisible(result) } ## loop over the specification of a cluster rgl.ellipsoids <- function(positions, sizes, angles,...){ N <- NROW(positions) ll <- lapply(seq(1,...