API Documentation for Mapper

class mdonatello.mapper.FunctionalGroupHandler[source]

Bases: object

A class that is responsible for handling functional groups in molecules.

Parameters:

molRDKit.Chem.Mol

An RDKit molecule object that represents the molecule in which functional groups are identified.

fgstr

The functional group for which the color is requested.

Returns:

fg_countsdict

A dictionary with functional group names as keys and lists of atom indices as values, representing the atoms involved in each functional group.

colorTuple[float, float, float]

An RGB tuple representing the color assigned to the specified functional group.

static calculate_functional_groups(mol)[source]

Identifies, calculates and counts the functional groups present in the given RDKit molecule.

Parameters:

molRDKit.Chem.Mol

An RDKit molecule object representing the molecule in which functional groups are identified.

Returns:

fg_countsdict

A dictionary with functional group names as keys and lists of atom indices as values, representing the atoms involved in each functional group.

static get_color_for_functional_group(fg)[source]

Determines the color associated with the given functional group based on its chemical structure.

Parameters:

fgstr

The functional group for which the color is required.

Returns:

colorTuple[float, float, float]

An RGB tuple representing the color assigned to the specified functional group.

class mdonatello.mapper.PharmacophoreColorMapper[source]

Bases: object

A class for mapping pharmacophore features according to their respective colors.

Parameters:

familystr

The pharmacophore feature family for which the color is requested.

Returns:

colorTuple[float, float, float]

An RGB tuple representing the color assigned to the specified pharmacophore feature family.

static get_color_for_pharmacophore(family: str) Tuple[float, float, float][source]

Determines the color associated with the given pharmacophore feature family.

Parameters:

familystr

The pharmacophore feature family for which the color is required.

Returns:

colorTuple[float, float, float]

An RGB tuple representing the color assigned to the specified pharmacophore feature.

FunctionalGroupHandler()

A class that is responsible for handling functional groups in molecules.

PharmacophoreColorMapper()

A class for mapping pharmacophore features according to their respective colors.