赞
踩
library(IDPmisc)
set.seed(1234)
n=10000
c1=matrix(rnorm(n,mean=0,sd=.5),ncol=2)
c2=matrix(rnorm(n,mean=3,sd=2),ncol=2)
mydata=rbind(c1,c2)
mydata=as.data.frame(mydata)
names(mydata)=c("x","y")
with(mydata,iplot(x,y,main="Image Scatter Plot with Color Indicating Density"))
library(gclus)
mydata=mtcars[c(1,3,5,6)]
mydata.corr=abs(cor(mydata))
mycolors=dmat.color(mydata.corr)
myorder=order.single(mydata.corr)
cpairs(mydata,myorder,panel.colors=mycolors,gap=.5,main="Variables Ordered and Colored by Correlation")```
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。