docs: function partitionValueToIndex (partition, value) {
    var group;
  
    if (!partition) {
      // no(sub)partitioning return first element
      return 0;
    }
  
    // with (sub)partitioning
    group = partition.groups.get(value, 'value');
  
    if (group) {
      // string in partition
      return group.groupIndex;
    } else {
      // string not in partition
      return -1;
    }
  }