zagreb_index_m1#
- skfp.descriptors.zagreb_index_m1(mol: Mol) int #
First Zagreb Index.
Calculates the first Zagreb index [1], defined as the sum of the squares of the degrees of all atoms in the molecule. Also known as simply the Zagreb index. It is a measure of molecular branching.
- Parameters:
mol (RDKit
Mol
object) – The molecule for which the first Zagreb index is to be calculated.
References
Examples
>>> from rdkit.Chem import MolFromSmiles >>> from skfp.descriptors import zagreb_index_m1 >>> mol = MolFromSmiles("C1=CC=CC=C1") # Benzene >>> zagreb_index_m1(mol) 24