Comparing 2 rasterbricks using functions from TSdist package
Hi Jackson, you could use the complete.cases function to remove the pairs with NA before run the distance function as bellow. # CorDistance function does not handle NAs x <- cbind(as.vector(s[[1]]), as.vector(s2[[1]])) select.rows <- complete.cases(x) CorDistance(x[select.rows, ] ) Cheers!
Frederico Faleiro Postdoctoral Researcher in the INCT-EECBio (https://www.eecbio.ufg.br/) Department of Ecology | Institute of Biological Science | Federal University of Goi?s | Brazil RG: https://www.researchgate.net/profile/Frederico_Faleiro CV: http://lattes.cnpq.br/4926404840659003 [[alternative HTML version deleted]]