remove all atoms
762549
@Override
	public void clearAtoms() {
		atoms.clear();
		setPDBFlag(false);
		if ( atomNameLookup != null)
			atomNameLookup.clear();
	}
229188
public void removeAllZeros() {
    Iterator<Map.Entry<K, AtomicLong>> entryIterator = map.entrySet().iterator();
    while (entryIterator.hasNext()) {
      Map.Entry<K, AtomicLong> entry = entryIterator.next();
      AtomicLong atomic = entry.getValue();
      if (atomic != null && atomic.get() == 0L) {
        entryIterator.remove();
      }
    }
  }
1355412
def _cleanup(self, ref):
        ''
        self.transitor_states[self._weakref_holder[ref]] -= 1
        del self._weakref_holder[ref]
388527
def displace(x,y,z)
      Atom.new(self.x+x, self.y+y, self.z+z, self.species, self.constrain)
    end
868535
public void cleanup() {
    keys.cleanup();
    counts.cleanup();
    dictionary.cleanup();
    // Decrement the dictionary memory by the total size of all the elements
    memoryEstimate.decrementDictionaryMemory(SizeOf.SIZE_OF_LONG * numElements);
  }
1301961
public static void removeAtomAndConnectedElectronContainers(IChemModel chemModel, IAtom atom) {
        ICrystal crystal = chemModel.getCrystal();
        if (crystal != null) {
            if (crystal.contains(atom)) {
                crystal.removeAtom(atom);
            }
            return;
        }
        IAtomContainerSet moleculeSet = chemModel.getMoleculeSet();
        if (moleculeSet != null) {
            MoleculeSetManipulator.removeAtomAndConnectedElectronContainers(moleculeSet, atom);
        }
        IReactionSet reactionSet = chemModel.getReactionSet();
        if (reactionSet != null) {
            ReactionSetManipulator.removeAtomAndConnectedElectronContainers(reactionSet, atom);
        }
    }
253783
def clear(self):
        
        for variable in self._project.variables.list(all=True):
            variable.delete()
1026084
def cleanup(self):
        """"""

        if not len(self.water_ids) == 0:
            # Hide all non-interacting water molecules
            water_selection = []
            for wid in self.water_ids:
                water_selection.append('serialNumber=%i' % wid)
            self.rc("~display :HOH")
            self.rc("display :@/%s" % " or ".join(water_selection))

        # Show all interacting binding site residues
        self.rc("~display #%i & ~:/isHet" % self.model_dict[self.plipname])
        self.rc("display :%s" % ",".join([str(self.atoms[bsid].residue.id) for bsid in self.bs_res_ids]))
        self.rc("color lightblue :HOH")
569444
def delete_all( name )
      rv = []
      each_attribute { |attribute| 
        rv << attribute if attribute.expanded_name == name
      }
      rv.each{ |attr| attr.remove }
      return rv
    end
1308513
def delete(self, s, p, o):
        """"""
        with self.walrus.atomic():
            for key in self.keys_for_values(s, p, o):
                del self._z[key]
245705
def remove_all(self):
        ''''''
        if self._children:
            for child in self._children:
                if isinstance(child, String):
                    child._parent = None
            self._children = []
319767
def remove_all(gset, elem):
    
    n = 0
    while True:
        try:
            remove_once(gset, elem)
            n = n + 1
        except RemoveError:
            return n
137968
def delete_atom(self, *atom_numbers):
        
        for atom_number in atom_numbers:
            deletion_atom = self.atom_by_number(atom_number=atom_number)

            # update atom numbers
            for atom in self.atoms:
                if int(atom.atom_number) > int(atom_number):
                    atom.atom_number = str(int(atom.atom_number) - 1)

            # find index of a bond to remove and update ctab data dict with new atom numbers
            for index, bond in enumerate(self.bonds):
                bond.update_atom_numbers()
                if atom_number in {bond.first_atom_number, bond.second_atom_number}:
                    self.bonds.remove(bond)

            # remove atom from neighbors list
            for atom in self.atoms:
                if deletion_atom in atom.neighbors:
                    atom.neighbors.remove(deletion_atom)

            self.atoms.remove(deletion_atom)
755476
@Override
    public void removeAtom(IAtom atom) {
        int position = getAtomNumber(atom);
        if (position != -1) {
            for (int i = 0; i < bondCount; i++) {
                if (bonds[i].contains(atom)) {
                    removeBond(i);
                    --i;
                }
            }
            for (int i = 0; i < lonePairCount; i++) {
                if (lonePairs[i].contains(atom)) {
                    removeLonePair(i);
                    --i;
                }
            }
            for (int i = 0; i < singleElectronCount; i++) {
                if (singleElectrons[i].contains(atom)) {
                    removeSingleElectron(i);
                    --i;
                }
            }
            removeAtomOnly(position);
        }
        notifyChanged();
    }
1118485
public function removeAll()
    {
        $portableElements = $this->getAll();
        foreach ($portableElements as $identifier => $versions) {
            $this->removeAllVersions($identifier);
        }
    }
579229
def unhide_selected():
    ''''''
    
    hidden_state = current_representation().hidden_state
    selection_state = current_representation().selection_state

    res = {}
    # Take the hidden state and flip the selected atoms bits.
    for k in selection_state:
        visible = hidden_state[k].invert()
        visible_and_selected = visible.add(selection_state[k]) # Add some atoms to be visible
        res[k] = visible_and_selected.invert()
    
    current_representation().hide(res)
721298
@Override
    public void removeAllAtomContainers() {
        for (int pos = atomContainerCount - 1; pos >= 0; pos--) {
            multipliers[pos] = 0.0;
            atomContainers[pos] = null;
        }
        atomContainerCount = 0;
    }