Skip to content
Prev 12347 / 63461 Next

Incorrect handling of NA's in cor() (PR#6750)

Marek Ancukiewicz wrote:
Whoops. My apologies!!!


In R-1.9.0 beta I get:

cor(x[!is.na(x)&!is.na(y)],y[!is.na(x)&!is.na(y)],method="s")
# [1] -0.4
cor(x,y,use="complete.obs", method="s")
# [1] -0.5291503

I'll take a look!

Uwe