Skip to content
Prev 30029 / 398503 Next

cor.test observations limit

Hi,

Is there a limit on the number of observations for using cor.test. For
example,
Error in if (q > (n^3 - n)/6) pspearman(q - 1, n, lower.tail = FALSE) else
pspearman(q,  : 
        missing value where logical needed
In addition: Warning message: 
NAs introduced by coercion 

I mainly want to calculate the spearman correlation rho for a data with
missing values. But the rcorr function in Hmisc library (from
Hmisc_1.4.2.zip) gave me an error message
Error in rcorr(tmp[5600:5900, 1:2], type = "spearman") : 
        NA/NaN/Inf in foreign function call (arg 1)

Any help is appreciated,

Ming-Chung Li