I would like to be able to parse a molecule into its functional groups, and, also, know the number of occurrences of each.
A similar question was asked on matter modelling specifically for xyz files. I am going to assume at this point most large databases will have molecules either a SMILES or SMARTS tag, or, have a tag that can be converted into a SMILES or SMARTS.
Looking over the code, which frankly captures the spirit of what I want, there seems to be alot of hardcoding. Is it possible to simply query a program(command line driven) with a molecules SMILE ID and get all of its functionals back?
I know you can ask rdkit if a molecule has a specific functional, but I don't really want that since I don't want to make a list of all possible functionals and then figure out how to count them in rdkit, as well as remove duplicates i.e, a parse for COOH would count as an carboxylic acid, but a separate parse for OH would return true for that same group, and a separate parse for =O would also return true, so I would have to correct for this. Also, I would want that to return as a carboxylic acid, not as an =O, OH and some kind of C. That affects a group contribution method in an undesired way.
Finally, I need every atom to be accounted for.
Python would be much preferred.