correlation function always NA

前端 未结 1 1606
清酒与你
清酒与你 2021-01-25 18:47

I\'m trying to find the correlations with this function but I just get NA for each input:

corr <- function(directory, threshold = 0) {

  filenames <- list         


        
1条回答
  •  广开言路
    2021-01-25 19:29

    The function cor has an argument use, which controls how it deals with missing observations, i.e. NAs. You might try setting it to use = "complete.obs".

    0 讨论(0)
提交回复
热议问题