Leonard Mada wrote:
I entered in column B(1): =A1 + 1, that is I added the value 1 for
every element in column A. That said, data values in columns A and B
should be totally correlated. The NIST accepts a value of -0.999, but:
They don't accept a value of -0.999 instead of 1, they just
Leonard Mada wrote:
Mind if I ask, in which file is the CORREL function defined?
Tests are still useful to see where the algorithm fails (and
purportedly, the new algorithm should be correct). Extensive test cases
are always welcome.
sc/source/core/tool/interpr3.cxx, method
Niklas Nebel wrote:
sc/source/core/tool/interpr3.cxx, method ScInterpreter::ScCorrel.
Calc uses indeed the *naïve algorithm* to compute the Correlation
Coefficient (see Wikipedia).
if (!pMat1-IsString(i,j) !pMat2-IsString(i,j))
{
fValX = pMat1-GetDouble(i,j);
fValY = pMat2-GetDouble(i,j);
Hi Leonard,
On Friday, 2006-11-10 17:13:00 +0200, Leonard Mada wrote:
unsigned int count = 0; // Counter for values
// DO WE NEED AN ??? fCount ???
Nah.. there won't be more than 2^32 matrix elements..
OR is (unsigned int) count OK
size_t respectively SCSIZE is preferred instead for clear
Hi Leonard,
On Friday, 2006-11-10 18:32:23 +0200, Leonard Mada wrote:
1. I forget a count++; in the first for LOOP
[inside the: if (!pMat1-IsString(i,j) !pMat2-IsString(i,j)) {} body]
2. because this count would be from 1 to n, the 2nd for LOOP should be
modified accordingly:
for(j