Is there a simple way to count functional groups?


I'm having a list of SMILES and I would like to receive columns which contain the numbers of each functional group for a molecule.


I've noticed that there is an RDKit Functional Group Filter Node which lists many functional groups. Since there is a node to filter by functional groups I assumed that there might also be one that counts and lists those functional groups.


Help is much appreciated!

Kind regards


The SMARTS patterns for the functional groups are viewable if you press the 'i' button in the Functional Group filter node - the best you could do probably at the moment is to use those as the basis for a second input table for the RDKit Substructure Counter node, although I would assume that it wouldn't be a huge leap for the RDKit developers to create a counter rather than filter version of the FG node


1 Like


that helped me a lot already - thank you very much!

Also I'd really appreciate such a node for future...



The functional group definitions that the RDKit uses for the Functional Group Filter node happen to all be in github:

Thanks to the fact that KNIME's file reader node can read from a URL, you can use these directly in a workflow after a bit of post-processing.

The attached workflow does just that.

Since the RDKit repo has another set of functional groups (these were collected for a different purpose and are broader, but perhaps not as carefully defined):

I created a second metanode that reads those in and does the required post-processing. 

And, finally, since there is also a set of SMARTS for "Topliss descriptors":

I created a metanode for those as well.

Hopefully the general pattern I use here, as well as the workflow itself, is useful.




Hey greg,

thanks this workflow is very helpful!!