COR calculates the correlation matrix X and Y can contain missing values encoded with NaN. NaN's are skipped, NaN do not result in a NaN output. (Its assumed that the occurence of NaN's is uncorrelated) The output gives NaN only if there are insufficient input data COR(X); calculates the (auto-)correlation matrix of X COR(X,Y); calculates the crosscorrelation between X and Y c = COR(...); c is the correlation matrix NOTE: Under certain circumstances (Missing values and small number of samples) abs(COR) can be larger than 1. If you need abs(COR)<=1, use CORRCOEF. CORRCOEF garantees abs(COR)<=1. see also: SUMSKIPNAN, COVM, COV, CORRCOEF REFERENCES: http://mathworld.wolfram.com/CorrelationCoefficient.html