Deletes unused grid row/cols
193229
def remove_unused_grid_rc(self):
        """"""

        if 'columns' in self['layout']:
            ckeys = tuple(self['layout']['columns'].keys())
            for key in ckeys:
                value = int(key)
                if value > self.max_col:
                    del self['layout']['columns'][key]
        if 'rows' in self['layout']:
            rkeys = tuple(self['layout']['rows'].keys())
            for key in rkeys:
                value = int(key)
                if value > self.max_row:
                    del self['layout']['rows'][key]
208907
def delete_blank_columns!(*options)
      exceptions = extract_exceptions(options)

      (columns.map(&:key) - exceptions).each do |key|
        if rows.all? { |row| is_blank?(row[key]) || is_zero?(row[key]) } # rubocop:disable Style/IfUnlessModifier
          delete_column key
        end
      end
    end
88999
def remove_empty_cols(records):
    """"""
    # In case it's a generator, turn it into a list
    records = list(records)
    seqstrs = [str(rec.seq) for rec in records]
    clean_cols = [col
                  for col in zip(*seqstrs)
                  if not all(c == '-' for c in col)]
    clean_seqs = [''.join(row)
                  for row in zip(*clean_cols)]
    for rec, clean_seq in zip(records, clean_seqs):
        yield SeqRecord(Seq(clean_seq, rec.seq.alphabet), id=rec.id,
                        name=rec.name, description=rec.description,
                        dbxrefs=rec.dbxrefs, features=rec.features,
                        annotations=rec.annotations,
                        letter_annotations=rec.letter_annotations)
340425
protected void cleanupStaleContexts(final Set<?> rowIds) {
		RepeaterModel model = getOrCreateComponentModel();

		if (model.rowContextMap != null) {
			for (Iterator<Map.Entry<Object, SubUIContext>> i = model.rowContextMap.entrySet().
					iterator(); i.hasNext();) {
				Map.Entry<Object, SubUIContext> entry = i.next();
				Object rowId = entry.getKey();

				if (!rowIds.contains(rowId)) {
					i.remove();
				}
			}
			if (model.rowContextMap.isEmpty()) {
				model.rowContextMap = null;
			}
		}
	}
502000
private void removeUseless() {
    Set<Map.Entry<String, PropertyNode>> entries = _children.entrySet();
    for (Iterator<Map.Entry<String, PropertyNode>> it = entries.iterator(); it.hasNext(); ) {
      Map.Entry<String, PropertyNode> entry = it.next();
      PropertyNode child = entry.getValue();
      child.removeUseless();
      if (child.isUseless()) {
        it.remove();
      }
    }
  }
842168
private void cleanup() {
        Entry<K, V>[] tab = this.table;

        for (int i = tab.length ; i-- > 0 ;) {
            for (Entry<K, V> e = tab[i], prev = null; e != null; e = e.next) {
                if (e.get() == null) {
                    // Clean up after a cleared Reference.
                    this.modCount++;
                    if (prev != null) {
                        prev.next = e.next;
                    } else {
                        tab[i] = e.next;
                    }
                    this.count--;
                } else {
                    prev = e;
                }
            }
        }
    }
1365973
function removeColumn(values, col, colsPerRow) {
  var n = 0;
  for (var i = 0, l = values.length; i < l; i++) {
    if (i % colsPerRow !== col) values[n++] = values[i];
  }
  values.length = n;
}
1105545
def _redraw(self):
        
        if self._blank_label:
            self._blank_label.grid_forget()
            self._blank_label.destroy()
            self._blank_label = None

        for slot in self._slots:
            slot.grid_forget()

        self._slots = [slot for slot in self._slots if not slot.deleted]

        max_per_col = 8
        for i, slot in enumerate(self._slots):
            slot.grid(row=i % max_per_col,
                      column=int(i / max_per_col), sticky='ew')
55254
function() {
    var elThead = this._elThead;
    if(elThead) {
        var elTable = elThead.parentNode;
        Ev.purgeElement(elThead, true);
        this._destroyColumnHelpers();
        elTable.removeChild(elThead);
        this._elThead = null;
    }
}
1021040
public void clear () {
		minWidth = null;
		minHeight = null;
		prefWidth = null;
		prefHeight = null;
		maxWidth = null;
		maxHeight = null;
		spaceTop = null;
		spaceLeft = null;
		spaceBottom = null;
		spaceRight = null;
		padTop = null;
		padLeft = null;
		padBottom = null;
		padRight = null;
		fillX = null;
		fillY = null;
		align = null;
		expandX = null;
		expandY = null;
		ignore = null;
		colspan = null;
		uniformX = null;
		uniformY = null;
	}
1359221
private void emptyCells(Row tmplRow, int rowOffset, Row row, int colStart, int colEnd) {
        for (int i = colStart; i <= colEnd; ++i) {
            newCell(tmplRow, i, rowOffset, row, "", 0);
        }
    }
1255276
function() {
            var oldRow = api.getParentElement(this.cell, { nodeName: ["TR"] });
            if (oldRow) {
                this.setTableMap();
                this.idx = this.getMapIndex(this.cell);
                if (this.idx !== false) {
                    var modRow = this.map[this.idx.row];
                    for (var cidx = 0, cmax = modRow.length; cidx < cmax; cidx++) {
                        if (!modRow[cidx].modified) {
                            this.setCellAsModified(modRow[cidx]);
                            this.removeRowCell(modRow[cidx]);
                        }
                    }
                }
                removeElement(oldRow);
            }
        }
529034
public void clear() {
	column = new String[0];
	types = null;
	rows = new Vector();
	ncolumns = nrows = 0;
	atmaxrows = false;
    }
915426
def __clear_covers(self):
        """"""
        for i in range(self.n):
            self.row_covered[i] = False
            self.col_covered[i] = False
892778
def extract_col(self, col):
        
        new_col = [row[col] for row in self.grid]
        return new_col
640961
def reset(self):
        
        self.grid = [[0 for dummy_l in range(self.grid_width)] for dummy_l in range(self.grid_height)]
577772
def clean_table(table, number_of_colums)
      above_row = []
      #filter if they are not last column, and they are same as the item on the row above
      table.reduce([]) { |result, row|
        result <<  row.each_with_index.map do |item,i|
          if i == number_of_colums
            item 
          else
            item == above_row[i] ? '' : item 
          end
        end
        above_row = row
        result
      }
    end