select the given range by qmodel indices
335221
def _update_selection(self, qindex1, qindex2):
        
        m = self.model()
        self._do_select(m.qindex2index(qindex1), m.qindex2index(qindex2))
100065
def selectge(table, field, value, complement=False):
    """"""

    value = Comparable(value)
    return selectop(table, field, value, operator.ge, complement=complement)
217183
def selection_range(self):  # XXX: shouldn't this return `None` if there is no selection???
        
        if self.selection:
            from_, to = sorted([self.cursor_position, self.selection.original_cursor_position])
        else:
            from_, to = self.cursor_position, self.cursor_position

        return from_, to
1012935
def SelectByIndex(cls, index):
        ''' 
        '''
        try:
            Select(cls._element()).select_by_index(int(index))
        except:
            return False
62773
def toggleSelection(self, index, comp):
        """"""
        self.model.toggleSelection(index.row(), comp)
644884
def select(clas,pool_or_cursor,**kwargs):
    ""
    columns = kwargs.pop('columns','*')
    # todo(awinter): write a test for whether eqexpr matters; figure out pg behavior and apply to pgmock
    query="select %s from %s"%(columns,clas.TABLE)
    if kwargs: query+=' where %s'%' and '.join('%s=%%s'%k for k in kwargs)
    return select_or_execute(pool_or_cursor,query,tuple(kwargs.values()))
1371082
def sample_range(range, seed=nil)
      srand seed if seed
      rand * (range.end - range.begin) + range.begin
    end
734992
def selectgt(table, field, value, complement=False):
    """"""

    value = Comparable(value)
    return selectop(table, field, value, operator.gt, complement=complement)
74004
def select(self, Class, set=None, recursive=True,  ignore=True):
        """"""
        if self.mode == Mode.MEMORY:
            for t in self.data:
                if Class.__name__ == 'Text':
                    yield t
                else:
                    for e in t.select(Class,set,recursive,ignore):
                        yield e
1365309
function selectRange(range, window) {
      var selection = window.getSelection();
      selection.removeAllRanges();
      selection.addRange(range);
    }
338196
def selection_range(self):
        
        selected = self.selectionModel().selection()
        """:type: QItemSelection """

        if selected.isEmpty():
            return -1, -1

        min_row = min(rng.top() for rng in selected)
        max_row = max(rng.bottom() for rng in selected)

        return min_row, max_row
313584
def select(self, axis, index, force_copy: bool = False):
        """"""
        if axis == 0:
            if index == slice(None) and not force_copy:
                return self
            return self[index]
        else:
            raise ValueError("In Histogram1D.select(), axis must be 0.")
398564
def select(self, idx):
        
        data = {}
        for k in self.data:
            data[k] = self.data[k][idx]
        return self._return(data=data)
740607
def select_action(self, q_values):
        
        assert q_values.ndim == 1
        action = np.argmax(q_values)
        return action
1353259
function selectionSet (elem) {
  const sel = document.getSelection()
  const range = document.createRange()
  range.selectNodeContents(elem)
  sel.removeAllRanges()
  sel.addRange(range)
}
57808
function(model) {
    const maxLen = model.get("seq").length;
    const selection = [];
    const sels = this.g.selcol.getSelForRow(model.get("id"));
    const rows = find(sels, function(el) { return el.get("type") === "row"; });
    if ((typeof rows !== "undefined" && rows !== null)) {
      // full match
      const end = maxLen - 1;
      for (let n = 0; n <= end; n++) {
        selection.push(n);
      }
    } else if (sels.length > 0) {
      for (let i = 0, sel; i < sels.length; i++) {
        sel = sels[i];
        const start = sel.get("xStart");
        const end = sel.get("xEnd");
        for (let n = start; n <= end; n++) {
          selection.push(n);
        }
      }
    }

    return selection;
  }
429168
public <T extends IItem & IExpandable> void selectRange(int from, int to, boolean select) {
        selectRange(from, to, select, false);
    }