[R] Correlations

Prof Brian Ripley ripley at stats.ox.ac.uk
Thu Oct 9 14:52:34 CEST 2003


On Thu, 9 Oct 2003, Bobbie van der Westhuizen wrote:

> Hi I am trying out R for the first time and it seems to work nice.
> 
> I also try it out on a LINUX platform aswell as on Windows. I downloaded the 
> new version of R for windows (version 8.1.0) but something look not right in 
> the calculations of correlations between traits when I use the next command:
> 
> >cor(fc,use="pairwise")
> 
> The correlation return between the same trait (that must be 1.000) is not 1 
> and sometimes it is 0.37?? When I run the same scrip with the same data in 
> Linux the correlation is correctly, 1.000. And when I run the following scrip 
> in 1.8.0 for windows it returns the correct correlation of 1.000.
> 
> >cor.test(BIRHTMASS,BIRHTMASS,na.rm=T,method="pearson")
> 
> Could there be a bug in this version of Windows?

Given that R 1.8.0 (sic) for Windows is not yet on CRAN, there is at least
a bug in your description, and undoubtedly there are bugs in Windows.

If you want to discuss a bug in R, please consult the FAQ and provide 
proper version information and a reproducible example.

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list