pysoftk.torsional package

Submodules

pysoftk.torsional.torsional module

class pysoftk.torsional.torsional.Torsional(mol)[source]

Bases: object

A class for detecting torsional angles in a linear conjugated polymer.

Examples

draw_molecule(mol, name_pic, atoms_idx)[source]

Function to print a molecule into a PNG file.

Parameters:
  • mol (rdkit.Chem.rdchem.Mol) – RDKit Mol object

  • name_pic (str) – Name of the created PNG object

  • atoms_idx (List[tup int]) – List of tuples of atomic indexes to be highligthed.

Returns:

rdkit.Draw.MolToFile Object

Return type:

None

list_dhdl_atoms()[source]

Function to compute all dihedral atoms

Returns:

List – List of atomic indexes for dihedral atoms

Return type:

int

mol_graph()[source]

Function to create a NetworkX graph based on an RDKit molecule.

Returns:

G – A networkx graph object updated with an RDKit Mol object.

Return type:

Networkx.Graph

mol_graph_neigh(mol)[source]

Function to compute adjacency matrix from an RDKit Mol object.

Returns:

mol – RDKit Mol object

Return type:

rdkit.Chem.rdchem.Mol

plot_trs_ang(name)[source]

Function to plot torsional atoms from an RDKit Mol Object.

Parameters:

name (str) – Name of the RDKit Mol object

Returns:

draw_molecule – A PNG RDKit Mol object

Return type:

PNG

seek_angles()[source]

List of torsional angles in a planar polymer.

Returns:

List – List of atomic indexes for torsional angles

Return type:

int

show_atom_number(mol, label)[source]

Function to set atomic numbers to an RDKit Mol object.

Parameters:
  • label (str) – Added Atomic Property to an RDKit Mol Object

  • mol (rdkit.Chem.rdchem.Mol) – RDKit Mol object

Returns:

mol – RDKit Mol object

Return type:

rdkit.Chem.rdchem.Mol

validate_mol(mol)[source]

Function that validates an object as RDKit Mol object.

Parameters:

mol (rdkit.Chem.rdchem.Mol) – RDKit Mol object

Returns:

mol – RDKit Mol object

Return type:

rdkit.Chem.rdchem.Mol

Module contents