[R] Matrix for correlation

R. Michael Weylandt michael.weylandt at gmail.com
Tue Nov 29 16:56:42 CET 2011

I'm not sure how you mean to calculate correlation if you have a
single observation of each medium....can you provide your data (or a
subset thereof) so we can see what you are actually working with and
if correlation makes sense.


On Tue, Nov 29, 2011 at 10:41 AM, Geophagus
<falk.hilliges at twain-systems.com> wrote:
> hi @ all,
> I have problem with creating a matrix for a cor() function.
> I try to use the cor() function on a matrix to test the correlation between
> each value in a column.
> Maybe like corr(x, method = xyz).
> My x has two columns maybe like this:
> Car      23
> Train    26
> Plane   25
> Cab     22
> Bike     15
> .... and so on.
> Now I want to calculate the correlation between Car and Train, Car and
> Plane, Train and Plane and so on.
> Sorry but I don't have a clue and I hope there is an easy way to solve my
> problem.
> Thanks a lot for all answers.
> Greetz Geo
> --
> View this message in context: http://r.789695.n4.nabble.com/Matrix-for-correlation-tp4119590p4119590.html
> Sent from the R help mailing list archive at Nabble.com.
> ______________________________________________
> 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.

More information about the R-help mailing list