Error in x validation loop end?

Hi. I want to use the x-validation loop with a neronal network.

I figured out that the mean squared errors are calculated in the X-Aggregator node as followed (directly copied from the code):

for (DataRow row : in) {
                RowKey key = row.getKey();
                DoubleValue target = (DoubleValue)row.getCell(targetColIndex);
                DoubleValue predict = (DoubleValue)row.getCell(predictColIndex);
                double d = (target.getDoubleValue() - predict.getDoubleValue());
                errorSum += d * d;

                subExec.setProgress(r / (double)rowCount, "Calculating output "
                        + r + "/" + rowCount + " (\"" + key + "\")");

            errorSum = Math.sqrt(errorSum);


As I see it it is wrong. Isn't the mean sqaure error?:

mean(y(expected)-y(predicted)) * (y(expected)-y(predicted)) )

Here they calculate:

(sqrt(sum of all(y(expected)-y(predicted)) * (y(expected)-y(predicted)) )) ) /number of datasets

or is there a sense? First I thought it is the root mean square error.

But the in the root mean square error the root is calculated after the mean.

The code seems wrong to me, too.


The last line should be:

errorSum = Math.sqrt(errorSum/r); // note check for division by zero!


I'm new to KNIME and therefore don't know how to report a bug or just fix the code myself and check it in...

This has already been fixed some months ago.