sknano.core.atoms.IDAtoms¶
-
class
sknano.core.atoms.
IDAtoms
(atoms=None, casttype=True, **kwargs)[source][source]¶ An
Atoms
sub-class forIDAtom
s.Sub-class of
Atoms
class, and a container class for lists ofIDAtom
instances.Parameters: atoms : {None, sequence,
IDAtoms
}, optionalAttributes
M
Total mass of Atoms
.Natoms
Number of atoms in Atoms
.atom_ids
Alias for IDAtoms.ids
.elements
ndarray
ofAtom.element
s inAtoms
.fmtstr
ids
Return array of IDAtom.id
s.masses
ndarray
ofAtom.mass
s inAtoms
.mol_ids
Alias for IDAtoms.mols
.molecule_ids
Alias for IDAtoms.mols
.mols
Return array of IDAtom.mol
s.symbols
ndarray
ofAtom.symbol
s inAtoms
.Methods
append
(atom)assign_unique_ids
([starting_id])Assign unique IDAtom.id
to eachIDAtom
inIDAtoms
.clear
()copy
()count
(item)extend
(other)filter
(condition[, invert])Filter Atoms
by condition.filter_ids
(atom_ids[, invert])Filter Atoms
byIDAtoms.ids
inatom_ids
.filtered
(condition[, invert])Return new list of Atoms
filtered by condition.filtered_ids
(atom_ids[, invert])Return new Atoms
filtered byIDAtoms.ids
inatom_ids
.get_atom
(id)Get IDAtom
withXatom.id
== id.get_atoms
([asarray])Return list of Atoms
.getatomattr
(attr)Get ndarray
of atom attributes attr.index
(item, *args)insert
(i, item)mapatomattr
([from_attr, to_attr, attrmap])Set/update atom attribute from another atom attribute with dict. pop
([i])remove
(item)reverse
()rezero
([epsilon])Set values with absolute value less than epsilon to zero. rotate
(**kwargs)Rotate Atom
vectors.sort
([key, reverse])todict
()translate
(t[, fix_anchor_points])Translate Atom
vectors byVector
t.