x, y, z の3次元を強引に2次元で可視化するという方法。
これはなかなかきつい。
正直うまくいっている気はあまりしない。
暫定版ということで。
N <- 30 x <- rnorm(n=N) y <- jitter(x,10^3) z <- jitter(y,10^4) dat <- data.frame(x,y,z) cor(data.frame(x,y,z)) dat$zz <- sqrt(dat$z-min(dat$z)) + .5 dat$zz.col <- 1-dat$zz/max(dat$zz) #遠近法のためにzが小さいものを先にプロット dat1 <- dat[order(dat$z),] X <- dat1$x Y <- dat1$y Z <- dat1$z ZZ <- dat1$zz ZZ.col <- dat1$zz.col plot(X,Y,type="n") points(X,Y,pch=16 ,cex=ZZ ,col=grey(ZZ.col)) legend(locator(1),legend=c("max(Z)","min(Z)") ,cex=1.5 ,pch=16 ,pt.cex=c(max(ZZ),min(ZZ)) ,col=grey(c(min(ZZ.col),max(ZZ.col))) )