Skip to content

compute pcorr

kgryte edited this page May 12, 2015 · 1 revision

Computes a correlation matrix for one or more numeric arrays.

var x = [ 1, 2, 3, 4, 5 ],
	y = [ 5, 4, 3, 2, 1 ];

var mat = compute.pcorr( x, y );
// returns [[1,-1],[-1,1]]
Clone this wiki locally