OEMakeTreeFP

bool OEMakeTreeFP(OEFingerPrint &fp, const OEChem::OEMolBase &mol)

Generates the OEFingerPrint object as a Tree fingerprint using default parameters.

fp

The OEFingerPrint object that is being initialized.

mol

The OEMolBase object from which the fingerprint is generated.

The following code snippet shows how to print out the string representation of a OEFPType_Tree fingerprint. This string encodes information about default parameters used to generate a OEFPType_Tree fingerprint.

fptype = oegraphsim.OEGetFPType(oegraphsim.OEFPType_Tree)
print(fptype.GetFPTypeString())

The output of the above code snippet is:

Tree,ver=2.0.0,size=4096,bonds=0-4,atype=AtmNum|Arom|Chiral|FCharge|HvyDeg|Hyb,btype=Order
bool OEMakeTreeFP(OEFingerPrint &fp, const OEChem::OEMolBase &mol,
                  unsigned int numbits,
                  unsigned int minbond, unsigned int maxbonds,
                  unsigned int atype, unsigned int btype)
fp

The OEFingerPrint object that is being initialized.

mol

The OEMolBase object from which the fingerprint is generated.

numbits

The size of the fingerprint in bits. This number has to be larger than or equal to \(2^4\) and smaller than \(2^{16}\).

minbonds, maxbonds

The smallest and largest tree fragments (in bonds) that are enumerated during the fingerprint generation. All enumerated tree fragments are hashed into the OEFingerPrint object.

atype

Defines which atom properties are encoded during the fingerprint generation. This value has to be either a value or a set of bitwise OR’d values from the OEFPAtomType namespace.

btype

Defines which bond properties are encoded during the fingerprint generation. This value has to be either a value or a set of bitwise OR’d values from the OEFPBondType namespace.

Note

For an empty molecule, both OEMakeTreeFP function will return false and the type of the fingerprint will be set to 0 (OEFingerPrint.GetFPTypeBase).

See also