我在數據讀取功能Rcorr NA /南/ INF在國外函數調用
data_features<-as.matrix(read.table("file.csv", header=TRUE,fill=TRUE));
然後轉化爲矩陣和利用圖書館「功能性」擺脫天道酬勤數據
dd <-as.matrix(data_xls)
dd[apply(dd, 1, Compose(is.finite, all)),]
然後我正在執行rcorr:
rcorr(dd)
這導致:
Error in rcorr(dd) : NA/NaN/Inf in foreign function call (arg 1)
In addition: Warning message:
In storage.mode(x) <- "double" : NAs introduced by coercion
沒有使用從功能撰寫,我會有這個問題時,創建一個矩陣 。目前,我在創建矩陣時沒有它,但是在執行rcorr之後再執行 。
[This](http://stackoverflow.com/a/18624605/2886003)有幫助嗎? – Llopis
[lm()NA/NaN/Inf error]的可能重複(http://stackoverflow.com/questions/8415778/lm-na-nan-inf-error) – Llopis
不,我用過,但都沒有工作。 – tesgoe