Trainable Weka Segmentation: try to speed up access to data in WarpingError.java
Trainable Weka Segmentation: multi-thread the reversion of splits and mergers to speed the process up.
Trainable Weka Segmentation: add method to calculate precision/recall stats per slice.
Trainable Weka Segmentation: read number of threads to use from the user preferences.
Trainable Weka Segmentation: add method to calculate precision/recall statistics per slice.
Trainable Weka Segmentation: in RandError.java, get number of threads to use from user preferences.
Trainable Weka Segmentation: correct precision and recall definitions, they were swapped.
Trainable Weka Segmentation: add class to store variation of information statistics.
Trainable Weka Segmentation: correct information in javadoc.
Trainable Weka Segmentation: add method to calculate statistics derived from the variation of information per slice.
Trainable Weka Segmentation: add method to calculate precision/recall statistics per slice.
Trainable Weka Segmentation: in WarpingError.java, make sure the number of threads is read from the user preferences.
Add an easily-called interactive test for Coloc 2

This helps developing in an IDE tremendously.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Coloc 2: Add Kendall's Tau-b rank correlation

Kendall's Tau-b rank correlation is said to be a better measure than
Spearman's rank correlation, and the latter was only preferred for a long
time because the former needs substantially more computational resources.

This implementation is very dumb and inefficient -- O(n^2) -- and is here
only for correctness.

A subsequent commit will replace it by an efficient method.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Introduce the PairIterator

For many measures, it should actually not be necessary to localize the
position or know about the mask. Therefore, let's abstract out an
interface for an iterator that returns pairs of values, and nothing else.

This will also make it substantially easier to test things, as one does no
longer need to construct full-blown image data structures just to test
an algorithm.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Add some documentation to the implementation of Kendall's Tau-b

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Use better names than getChannel1 and getChannel2

We are not getting the whole channel, after all. Just one sample of it.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Make the TwinCursor a PairIterator

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Add a test for the Kendall Tau-b algorithm

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Test more conditions of Kendall's Tau-b

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>