code: private ModifiableDoubleDBIDList getOrCreateColumn(int dim) {
      while(dim >= index.size()) {
        index.add(DBIDUtil.newDistanceDBIDList());
      }
      return index.get(dim);
    }
docs: Get (or create) a column.
  
  @param dim Dimension
  @return Column