public void pairsSortedByValue(final List<T> keyList, DoubleArrayList valueList) {
keys(keyList);
values(valueList);
final double[] v = valueList.elements();
Swapper swapper = new Swapper() {
@Override
public void swap(int a, int b) {
double t1 = v[a];
v[a] = v[b];
v[b] = t1;