[R] All against all correlation matrix with GGPLOT Facet

John Kane jrkrideau at inbox.com
Mon Jun 10 16:05:48 CEST 2013


No image.  The R-help list tends to strip out a lot of files. A pdf or txt usually gets through.  In any case I understand what you want this may do it.

library(ggplot2)
dat1  <-  data.frame( v = rnorm(13),
w = rnorm(13),
x = rnorm(13),
y = rnorm(13),
z = rnorm(13))
plotmatrix(dat1)

John Kane
Kingston ON Canada


> -----Original Message-----
> From: gundalav at gmail.com
> Sent: Mon, 10 Jun 2013 12:26:44 +0900
> To: r-help at stat.math.ethz.ch
> Subject: [R] All against all correlation matrix with GGPLOT Facet
> 
> I have the following data:
> 
> v <- rnorm(13)
> w <- rnorm(13)
> x <- rnorm(13)
> y <- rnorm(13)
> z <- rnorm(13)
> 
> 
> Using GGPLOT facet, what I want to do is to create a 5*5 matrix,
> where each cells plot the correlation between
> each pair of the above data. E.g. v-v,v-w; v-x,...,z-z
> 
> 
> What's the way to do it?
> Attached is the image.
> 
> GV.
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

____________________________________________________________
FREE ONLINE PHOTOSHARING - Share your photos online with your friends and family!
Visit http://www.inbox.com/photosharing to find out more!



More information about the R-help mailing list