Skip to content

Problem: using cor.test with by( )

3 messages · Che-hsu (Joe) Chang, Peter Dalgaard, Liviu Andronic

#
Che-hsu (Joe) Chang wrote:
Only the model formula interface to cor.test uses the data argument, so 
you need either

cor.test(x$A,x$B)

or

cor.test(~A+B, data=x)

  
    
#
On Sun, Mar 30, 2008 at 7:11 PM, Che-hsu (Joe) Chang <chjchang at gmail.com> wrote:
This recent thread [1] might prove of interest.
Liviu

[1] http://www.nabble.com/p-value-in-Spearman-rank-order-tt15738907.html