RDKitCalculateRMSD.py - Calculate RMSD between molecules
RDKitCalculateRMSD.py [--calcRMSD <RMSD, BestRMSD>] [--infileParams <Name,Value,...>] [--maxIters <number>] [--mode <OneToOne, AllToAll, FirstToAll>] [--overwrite] [-w <dir>] -r <reffile> -p <probefile> -o <outfile>
RDKitCalculateRMSD.py -h | --help | -e | --examples
Calculate Root Mean Square Distance (RMSD) between a set of similar molecules in reference and probe input files. The RDKit function fails to calculate RMSD values for dissimilar molecules. Consequently, a text string 'None' is written out as a RMSD value for dissimilar molecule pairs.
The supported input file formats are: Mol (.mol), SD (.sdf, .sd)
The supported output file formats are: CSV (.csv), TSV (.tsv, .txt)
Methodology for calculating RMSD values. Possible values: RMSD, BestRMSD. During BestRMSMode mode, the RDKit 'function AllChem.GetBestRMS' is used to align and calculate RMSD. This function calculates optimal RMSD for aligning two molecules, taking symmetry into account. Otherwise, the RMSD value is calculated using 'AllChem.AlignMol function' without changing the atom order. A word to the wise from RDKit documentation: The AllChem.GetBestRMS function will attempt to align all permutations of matching atom orders in both molecules, for some molecules it will lead to 'combinatorial explosion'.
A comma delimited list of parameter name and value pairs for reading molecules from files. The supported parameter names for different file formats, along with their default values, are shown below:
Maximum number of iterations to perform for each molecule pair during minimization of RMSD values. This option is ignored during BestRMSD mode.
Specify how molecules are handled in reference and probe input files during calculation of RMSD between reference and probe molecules. Possible values: OneToOne, AllToAll and AllToFirst. For OneToOne mode, the number of molecules in reference file must be equal to the number of molecules in probe file. The RMSD is calculated for each pair of molecules in the reference and probe file and written to the output file. For AllToAll mode, the RMSD is calculated for each reference molecule against all probe molecules. For FirstToAll mode, however, the RMSD is only calculated for the first reference molecule against all probe molecules.
Print this help message.
Probe input file name.
Reference input file name.
Output file name for writing out RMSD values. Supported text file extensions: csv or tsv.
Overwrite existing files.
Location of working directory which defaults to the current directory.
To calculate RMSD between pair of molecules in reference and probe molecules in 3D SD files and write out a CSV file containing calculated RMSD values along with appropriate molecule IDs, type:
To calculate RMSD between all molecules in reference and probe molecules in 3D SD files and write out a CSV file containing calculated RMSD values along with appropriate molecule IDs, type:
To calculate best RMSD between first molecule in reference all probe molecules in 3D SD files and write out a TSV file containing calculated RMSD values along with appropriate molecule IDs, type:
To calculate RMSD between all molecules in reference and probe molecules in 3D SD files without removing hydrogens and write out a TSV file containing calculated RMSD values along with appropriate molecule IDs, type:
RDKitCalculateMolecularDescriptors.py, RDKitCompareMoleculeShapes.py, RDKitConvertFileFormat.py, RDKitGenerateConformers.py, RDKitPerformMinimization.py
Copyright (C) 2018 Manish Sud. All rights reserved.
The functionality available in this script is implemented using RDKit, an open source toolkit for cheminformatics developed by Greg Landrum.
This file is part of MayaChemTools.
MayaChemTools is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.