I want to calculate the correlation between 2 numbers in SQL Server T-SQL. ie this http://en.wikipedia.org/wiki/Correlation
I have a table with 2 columns that have floating point values and I want to get the correlation between the values in a quick easy way.
Does anyone already have a script for this (or a UDF or stored proc) - or do I need to wade through the equation and do it myself?
thanks - Reddal
its MS SQL Server 2008 if that helps