Shuffle selected left row to right table model.
970948
public void shuffleSelectedLeftRowToRightTable()
	{
		final int selectedRow = leftTable.getSelectedRow();
		final T row = leftTable.getGenericTableModel().removeAt(selectedRow);
		rightTable.getGenericTableModel().add(row);
	}
1036480
def toggle(self, rows):
        ''
        for r in Progress(rows, 'toggling', total=len(self.rows)):
            if not self.unselectRow(r):
                self.selectRow(r)
431469
def sample(self, num):
        
        if num > len(self):
            return self.copy()
        elif num < 0:
            raise IndexError("Cannot sample a negative number of rows "
                             "from a DataTable")

        random_row_mask = ([True] * num) + ([False] * (len(self) - num))
        shuffle(random_row_mask)

        sampled_table = self.mask(random_row_mask)
        random_col_name = 'random_sorting_column'
        while random_col_name in sampled_table:
            random_col_name = '%030x' % randrange(16**30)
        sampled_table[random_col_name] = [random()
                                          for _ in xrange(len(sampled_table))]
        sampled_table.sort(random_col_name, inplace=True)
        del sampled_table[random_col_name]
        return sampled_table
1114356
def selectrows(self, rownrs):
        """"""
        t = self._selectrows(rownrs, name='')
        # selectrows returns a Table object, so turn that into table.
        return table(t, _oper=3)
46417
def shuffle(self, random=None):
		""""""
		random_.shuffle(self._list, random=random)
		for i, elem in enumerate(self._list):
			self._dict[elem] = i
799795
def shuffle(self, func, num_splits=None, **kwargs):
        
        if num_splits is None:
            num_splits = len(self.list_of_blocks)

        args = [self.axis, func, num_splits, kwargs]
        args.extend(self.list_of_blocks)
        return [
            PyarrowOnRayFramePartition(obj)
            for obj in deploy_ray_axis_func._remote(args, num_return_vals=num_splits)
        ]
503494
def putcellslice(self, rownr, value, blc, trc, inc=[]):
        """"""
        return self._table.putcellslice(self._column, rownr, value, blc, trc, inc)
517626
def model_from_list(l, header):
        """"""
        col = groups.sortableListe(PseudoAccesCategorie(n) for n in l)
        return MultiSelectModel(col, header)
216854
public void shuffle(long seed) {
        // just skip shuffle if there's only 1 example
        if (numExamples() < 2)
            return;

        //note here we use the same seed with different random objects guaranteeing same order

        List<INDArray> arrays = new ArrayList<>();
        List<int[]> dimensions = new ArrayList<>();

        arrays.add(getFeatures());
        dimensions.add(ArrayUtil.range(1, getFeatures().rank()));

        arrays.add(getLabels());
        dimensions.add(ArrayUtil.range(1, getLabels().rank()));

        if (featuresMask != null) {
            arrays.add(getFeaturesMaskArray());
            dimensions.add(ArrayUtil.range(1, getFeaturesMaskArray().rank()));
        }

        if (labelsMask != null) {
            arrays.add(getLabelsMaskArray());
            dimensions.add(ArrayUtil.range(1, getLabelsMaskArray().rank()));
        }

        Nd4j.shuffle(arrays, new Random(seed), dimensions);

        //As per CpuNDArrayFactory.shuffle(List<INDArray> arrays, Random rnd, List<int[]> dimensions) and libnd4j transforms.h shuffleKernelGeneric
        if (exampleMetaData != null) {
            int[] map = ArrayUtil.buildInterleavedVector(new Random(seed), numExamples());
            ArrayUtil.shuffleWithMap(exampleMetaData, map);
        }
    }
501399
def shuffle(self):
        

        args = list(self)
        random.shuffle(args)

        self.clear()
        super(DogeDeque, self).__init__(args)
1249181
def on_left_click(self, event, grid, choices):
        
        color = self.grid.GetCellBackgroundColour(event.GetRow(), event.GetCol())
        # allow user to cherry-pick cells for editing.  gets selection of meta key for mac, ctrl key for pc
        if event.ControlDown() or event.MetaDown():
            row, col = event.GetRow(), event.GetCol()
            if (row, col) not in self.dispersed_selection:
                self.dispersed_selection.append((row, col))
                self.grid.SetCellBackgroundColour(row, col, 'light blue')
            else:
                self.dispersed_selection.remove((row, col))
                self.grid.SetCellBackgroundColour(row, col, color)# 'white'
            self.grid.ForceRefresh()
            return
        if event.ShiftDown(): # allow user to highlight multiple consecutive cells in a column
            previous_col = self.grid.GetGridCursorCol()
            previous_row = self.grid.GetGridCursorRow()
            col = event.GetCol()
            row = event.GetRow()
            if col != previous_col:
                return
            else:
                if row > previous_row:
                    row_range = list(range(previous_row, row+1))
                else:
                    row_range = list(range(row, previous_row+1))
            for r in row_range:
                self.grid.SetCellBackgroundColour(r, col, 'light blue')
                self.selection.append((r, col))
            self.grid.ForceRefresh()
            return

        selection = False

        if self.dispersed_selection:
            is_dispersed = True
            selection = self.dispersed_selection

        if self.selection:
            is_dispersed = False
            selection = self.selection

        try:
            col = event.GetCol()
            row = event.GetRow()
        except AttributeError:
            row, col = selection[0][0], selection[0][1]

        self.grid.SetGridCursor(row, col)

        if col in list(choices.keys()): # column should have a pop-up menu
            menu = wx.Menu()
            two_tiered = choices[col][1]
            choices = choices[col][0]
            if not two_tiered: # menu is one tiered
                if 'CLEAR cell of all values' not in choices:
                    choices.insert(0, 'CLEAR cell of all values')
                for choice in choices:
                    if not choice:
                        choice = " " # prevents error if choice is an empty string
                    menuitem = menu.Append(wx.ID_ANY, str(choice))
                    self.window.Bind(wx.EVT_MENU, lambda event: self.on_select_menuitem(event, grid, row, col, selection), menuitem)
                self.show_menu(event, menu)
            else: # menu is two_tiered
                clear = menu.Append(-1, 'CLEAR cell of all values')
                self.window.Bind(wx.EVT_MENU, lambda event: self.on_select_menuitem(event, grid, row, col, selection), clear)
                for choice in sorted(choices.items()):
                    submenu = wx.Menu()
                    for item in choice[1]:
                        menuitem = submenu.Append(-1, str(item))
                        self.window.Bind(wx.EVT_MENU, lambda event: self.on_select_menuitem(event, grid, row, col, selection), menuitem)
                    menu.Append(-1, choice[0], submenu)
                self.show_menu(event, menu)

        if selection:
            # re-whiten the cells that were previously highlighted
            for row, col in selection:
                self.grid.SetCellBackgroundColour(row, col, self.col_color)
            self.dispersed_selection = []
            self.selection = []
            self.grid.ForceRefresh()
873248
def next_row(self):
        """"""
        row = self.currentIndex().row()
        rows = self.proxy_model.rowCount()
        if row + 1 == rows:
            row = -1
        self.selectRow(row + 1)
833427
public void addAllRightRowsToLeftTable()
	{
		leftTable.getGenericTableModel().addList(rightTable.getGenericTableModel().getData());
		rightTable.getGenericTableModel().clear();
	}
872417
def shuffle(self):
        
        if(self._clean.isDict()):
            return self._wrap(list())

        cloned = self.obj[:]

        random.shuffle(cloned)
        return self._wrap(cloned)
1331980
public void shuffleColumnsAndThenRows(ArrayList<String> columns, ArrayList<String> rows) throws Exception {
		doubleValues.clear();

		for (String column : columns) { //shuffle all values in the column
			ArrayList<Integer> rowIndex = new ArrayList<Integer>();
			for (int i = 0; i < rows.size(); i++) {
				rowIndex.add(i);
			}
			Collections.shuffle(rowIndex);
			for (int i = 0; i < rows.size(); i++) {
				String row = rows.get(i);
				int randomIndex = rowIndex.get(i);
				String destinationRow = rows.get(randomIndex);


				String temp = this.getCell(destinationRow, column);
				String value = this.getCell(row, column);
				this.addCell(destinationRow, column, value);
				this.addCell(row, column, temp);
			}
		}

		for (String row : rows) {
			ArrayList<Integer> columnIndex = new ArrayList<Integer>();
			for (int i = 0; i < columns.size(); i++) {
				columnIndex.add(i);
			}
			Collections.shuffle(columnIndex);
			for (int i = 0; i < columns.size(); i++) {
				String column = columns.get(i);

				int randomIndex = columnIndex.get(i);
				String destinationCol = columns.get(randomIndex);


				String temp = this.getCell(row, destinationCol);
				String value = this.getCell(row, column);
				this.addCell(row, destinationCol, value);
				this.addCell(row, column, temp);
			}
		}


	}
1048978
def randomRow(self):
        
        l = []
        for row in self.data:
            l.append(row)
        return random.choice(l)
244302
def previous_row(self):
        """"""
        row = self.currentIndex().row()
        rows = self.source_model.rowCount()
        if row == 0:
            row = rows
        self.selectRow(row - 1)