[R] Test statistic for Spearman correlation
    Brett Magill 
    bmagill at earthlink.net
       
    Thu May  1 14:45:18 CEST 2003
    
    
  
In the ouput below, what is the "S" statistic (S = 96) that is used for Spearman?  I don't have easy access to the books cited on the help page.  Other texts and web sources that I have found use t or z as a test for Spearman, perhaps inappropriately.  Can anyone tell me how S is computed or refer to a web resource?
I see from the code for that: 
  q <- as.integer((n^3 - n) * (1 - ESTIMATE)/6)
  STATISTIC <- c(S = q)  
I couldn't decipher the next part.  Would appreciate some help.
R 1.7.0 Windows 98.
_________________________________________
        Spearman's rank correlation rho
data:  x and y 
S = 96, p-value = 0.2324
alternative hypothesis: true rho is not equal to 0 
sample estimates:
      rho 
0.4181818
    
    
More information about the R-help
mailing list