Reputation: 541
I have a matrix z that spits out a 20 by 20 matrix with with values starting at -9 to -739. I downloaded rgl but I can't figure out how to use it with my matrix: z[i, j]
Upvotes: 3
Views: 107
Reputation: 226781
How about:
set.seed(101)
z <- matrix(sample(-739:-9,replace=TRUE,400),20)
library(rgl)
persp3d(z,col="gray")
Upvotes: 3