Molecules

class sknano.core.atoms.molecules.Molecules(molecules=None, update_item_class=True, **kwargs)[source] [edit on github][source]

Bases: sknano.core.collections.UserList

Base class for collection of Molecule objects.

Parameters:molecules ({None, sequence, Molecules}, optional) – if not None, then a list of Molecule instance objects or an existing Molecules instance object.

Attributes

Nmolecules Number of molecules in Molecules.
fmtstr Format string.
masses Return list of Molecule masses.

Methods

append(item)
clear()
copy()
count(item)
extend(other)
filter(condition[, invert]) Filter Molecules by condition.
filtered(condition[, invert])
get_molecules([asarray]) Return list of Molecules.
index(item, *args)
insert(i, item)
pop([i])
remove(item)
reverse()
rezero([epsilon]) Set really really small coordinates to zero.
rotate(**kwargs) Rotate Molecule position vectors.
sort([key, reverse])
todict() Return dict of constructor parameters.
translate(t[, fix_anchor_points]) Translate Molecule position vectors by Vector t.