AtomTypesFingerprints.pl - Generate atom types fingerprints for SD files
AtomTypesFingerprints.pl SDFile(s)...
AtomTypesFingerprints.pl [--AromaticityModel AromaticityModelType] [-a, --AtomIdentifierType AtomicInvariantsAtomTypes | DREIDINGAtomTypes | EStateAtomTypes | MMFF94AtomTypes | SLogPAtomTypes | SYBYLAtomTypes | TPSAAtomTypes | UFFAtomTypes] [--AtomicInvariantsToUse "AtomicInvariant, AtomicInvariant..."] [--FunctionalClassesToUse "FunctionalClass1,FunctionalClass2..."] [--AtomTypesSetToUse ArbitrarySize | FixedSize] [--BitsOrder Ascending | Descending] [-b, --BitStringFormat BinaryString | HexadecimalString] [--CompoundID DataFieldName or LabelPrefixString] [--CompoundIDLabel text] [--CompoundIDMode DataField | MolName | LabelPrefix | MolNameOrLabelPrefix] [--DataFields "FieldLabel1,FieldLabel2,..."] [-d, --DataFieldsMode All | Common | Specify | CompoundID] [-f, --Filter Yes | No] [--FingerprintsLabelMode FingerprintsLabelOnly | FingerprintsLabelWithIDs] [--FingerprintsLabel text] [-h, --help] [-k, --KeepLargestComponent Yes | No] [-m, --mode AtomTypesCount | AtomTypesBits] [-i, --IgnoreHydrogens Yes | No] [--OutDelim comma | tab | semicolon] [--output SD |FP | text | all] [-o, --overwrite] [-q, --quote Yes | No] [-r, --root RootName] [-s, --size number] [--ValuesPrecision number] [-v, --VectorStringFormat IDsAndValuesString | IDsAndValuesPairsString | ValuesAndIDsString | ValuesAndIDsPairsString] [-w, --WorkingDir DirName]
Generate atom types fingerprints for SDFile(s) and create appropriate SD, FP or CSV/TSV text file(s) containing fingerprints bit-vector or vector strings corresponding to molecular fingerprints.
Multiple SDFile names are separated by spaces. The valid file extensions are .sdf and .sd. All other file names are ignored. All the SD files in a current directory can be specified either by *.sdf or the current directory name.
The current release of MayaChemTools supports generation of atom types fingerpritns corresponding to following -a, --AtomIdentifierTypes:
Based on the values specified for -a, --AtomIdentifierType along with other specified parameters such as --AtomicInvariantsToUse and --FunctionalClassesToUse, initial atom types are assigned to all non-hydrogen atoms or all atoms in a molecule
Using the assigned atom types and specified -m, --Mode, one of the following types of fingerprints are generated:
For AtomTypesCount fingerprints, two types of atom types set size are allowed as value of --AtomTypesSetToUse option:
For AtomTypesBits fingerprints, only FixedSize atom type set is allowed.
ArbitrarySize corresponds to atom types detected in a molecule where as FixedSize implies a fix number of all possible atom types previously defined for a specific -a, --AtomIdentifierType.
Fix number of all possible atom types for supported AtomIdentifierTypes in current release of MayaChemTools are:
The current release of MayaChemTools generates the following atom types fingerprints bit-vector and vector strings:
Specify aromaticity model to use during detection of aromaticity. Possible values in the current release are: MDLAromaticityModel, TriposAromaticityModel, MMFFAromaticityModel, ChemAxonBasicAromaticityModel, ChemAxonGeneralAromaticityModel, DaylightAromaticityModel or MayaChemToolsAromaticityModel. Default value: MayaChemToolsAromaticityModel.
The supported aromaticity model names along with model specific control parameters are defined in AromaticityModelsData.csv, which is distributed with the current release and is available under lib/data directory. Molecule.pm module retrieves data from this file during class instantiation and makes it available to method DetectAromaticity for detecting aromaticity corresponding to a specific model.
Specify atom identifier type to use for assignment of atom types to hydrogen and/or non-hydrogen atoms during calculation of atom types fingerprints. Possible values in the current release are: AtomicInvariantsAtomTypes, DREIDINGAtomTypes, EStateAtomTypes, FunctionalClassAtomTypes, MMFF94AtomTypes, SLogPAtomTypes, SYBYLAtomTypes, TPSAAtomTypes, UFFAtomTypes. Default value: AtomicInvariantsAtomTypes.
This value is used during AtomicInvariantsAtomTypes value of a, --AtomIdentifierType option. It's a list of comma separated valid atomic invariant atom types.
Possible values for atomic invariants are: AS, X, BO, LBO, SB, DB, TB, H, Ar, RA, FC, MN, SM. Default value: AS,X,BO,H,FC.
The atomic invariants abbreviations correspond to:
Atom type generated by AtomTypes::AtomicInvariantsAtomTypes class corresponds to:
Except for AS which is a required atomic invariant in atom types, all other atomic invariants are optional. Atom type specification doesn't include atomic invariants with zero or undefined values.
In addition to usage of abbreviations for specifying atomic invariants, the following descriptive words are also allowed:
AtomTypes::AtomicInvariantsAtomTypes module is used to assign atomic invariant atom types.
This value is used during FunctionalClassAtomTypes value of a, --AtomIdentifierType option. It's a list of comma separated valid functional classes.
Possible values for atom functional classes are: Ar, CA, H, HBA, HBD, Hal, NI, PI, RA. Default value [ Ref 24 ]: HBD,HBA,PI,NI,Ar,Hal.
The functional class abbreviations correspond to:
AtomTypes::FunctionalClassAtomTypes module is used to assign functional class atom types. It uses following definitions [ Ref 60-61, Ref 65-66 ]:
Atom types set size to use during generation of atom types fingerprints.
Possible values for AtomTypesCount values of -m, --mode option: ArbitrarySize | FixedSize; Default value: ArbitrarySize.
Possible values for AtomTypesBits value of -m, --mode option: FixedSize; Default value: FixedSize.
FixedSize value is not supported for AtomicInvariantsAtomTypes value of -a, --AtomIdentifierType option.
ArbitrarySize corresponds to only atom types detected in molecule; FixedSize corresponds to fixed number of previously defined atom types for specified -a, --AtomIdentifierType.
Bits order to use during generation of fingerprints bit-vector string for AtomTypesBits value of =item --BitsOrder Ascending | Descending
Bits order to use during generation of fingerprints bit-vector string for AtomTypesBits value of -m, --mode option. Possible values: Ascending, Descending. Default: Ascending.
Ascending bit order which corresponds to first bit in each byte as the lowest bit as opposed to the highest bit.
Internally, bits are stored in Ascending order using Perl vec function. Regardless of machine order, big-endian or little-endian, vec function always considers first string byte as the lowest byte and first bit within each byte as the lowest bit.
Format of fingerprints bit-vector string data in output SD, FP or CSV/TSV text file(s) specified by --output used during AtomTypesBits value of -m, --mode option. Possible values: BinaryString, HexadecimalString. Default value: BinaryString.
BinaryString corresponds to an ASCII string containing 1s and 0s. HexadecimalString contains bit values in ASCII hexadecimal format.
Examples:
This value is --CompoundIDMode specific and indicates how compound ID is generated.
For DataField value of --CompoundIDMode option, it corresponds to datafield label name whose value is used as compound ID; otherwise, it's a prefix string used for generating compound IDs like LabelPrefixString<Number>. Default value, Cmpd, generates compound IDs which look like Cmpd<Number>.
Examples for DataField value of --CompoundIDMode:
Examples for LabelPrefix or MolNameOrLabelPrefix value of --CompoundIDMode:
The value specified above generates compound IDs which correspond to Compound<Number> instead of default value of Cmpd<Number>.
Specify compound ID column label for FP or CSV/TSV text file(s) used during CompoundID value of --DataFieldsMode option. Default: CompoundID.
Specify how to generate compound IDs and write to FP or CSV/TSV text file(s) along with generated fingerprints for FP | text | all values of --output option: use a SDFile(s) datafield value; use molname line from SDFile(s); generate a sequential ID with specific prefix; use combination of both MolName and LabelPrefix with usage of LabelPrefix values for empty molname lines.
Possible values: DataField | MolName | LabelPrefix | MolNameOrLabelPrefix. Default: LabelPrefix.
For MolNameAndLabelPrefix value of --CompoundIDMode, molname line in SDFile(s) takes precedence over sequential compound IDs generated using LabelPrefix and only empty molname values are replaced with sequential compound IDs.
This is only used for CompoundID value of --DataFieldsMode option.
Comma delimited list of SDFiles(s) data fields to extract and write to CSV/TSV text file(s) along with generated fingerprints for text | all values of --output option.
This is only used for Specify value of --DataFieldsMode option.
Examples:
Specify how data fields in SDFile(s) are transferred to output CSV/TSV text file(s) along with generated fingerprints for text | all values of --output option: transfer all SD data field; transfer SD data files common to all compounds; extract specified data fields; generate a compound ID using molname line, a compound prefix, or a combination of both. Possible values: All | Common | specify | CompoundID. Default value: CompoundID.
Specify whether to check and filter compound data in SDFile(s). Possible values: Yes or No. Default value: Yes.
By default, compound data is checked before calculating fingerprints and compounds containing atom data corresponding to non-element symbols or no atom data are ignored.
Specify how fingerprints label is generated in conjunction with --FingerprintsLabel option value: use fingerprints label generated only by --FingerprintsLabel option value or append atom type value IDs to --FingerprintsLabel option value.
Possible values: FingerprintsLabelOnly | FingerprintsLabelWithIDs. Default value: FingerprintsLabelOnly.
This option is only used for FixedSize value of -e, --AtomTypesSetToUse option during generation of AtomTypesCount fingerprints and ignored for AtomTypesBits.
Atom type IDs appended to --FingerprintsLabel value during FingerprintsLabelWithIDs values of --FingerprintsLabelMode correspond to fixed number of previously defined atom types.
SD data label or text file column label to use for fingerprints string in output SD or CSV/TSV text file(s) specified by --output. Default value: AtomTypesFingerprints.
Print this help message.
Ignore hydrogens during fingerprints generation. Possible values: Yes or No. Default value: Yes.
For yes value of -i, --IgnoreHydrogens, any explicit hydrogens are also used for generation of atom type fingerprints; implicit hydrogens are still ignored.
Generate fingerprints for only the largest component in molecule. Possible values: Yes or No. Default value: Yes.
For molecules containing multiple connected components, fingerprints can be generated in two different ways: use all connected components or just the largest connected component. By default, all atoms except for the largest connected component are deleted before generation of fingerprints.
Specify type of atom types fingerprints to generate for molecules in SDFile(s). Possible values: AtomTypesCount or AtomTypesBits. Default value: AtomTypesCount.
For AtomTypesCount values of -m, --mode option, a fingerprint vector string is generated. The vector string corresponding to AtomTypesCount contains count of atom types.
For AtomTypesBits value of -m, --mode option, a fingerprint bit-vector string containing zeros and ones indicating presence or absence of atom types is generated.
For AtomTypesCount atom types fingerprints, two types of atom types set size can be specified using -a, --AtomTypesSetToUse option: ArbitrarySize or FixedSize. ArbitrarySize corrresponds to only atom types detected in molecule; FixedSize corresponds to fixed number of atom types previously defined.
For AtomTypesBits atom types fingeprints, only FixedSize is allowed.
Combination of -m, --Mode and --AtomTypesSetToUse along with -a, --AtomtomIdentifierType allows generation of following different atom types fingerprints:
The default is to generate AtomicInvariantAtomTypes fingeprints corresponding to ArbitrarySize as value of --AtomTypesSetToUse option.
Delimiter for output CSV/TSV text file(s). Possible values: comma, tab, or semicolon Default value: comma.
Type of output files to generate. Possible values: SD, FP, text, or all. Default value: text.
Overwrite existing files.
Put quote around column values in output CSV/TSV text file(s). Possible values: Yes or No. Default value: Yes.
New file name is generated using the root: <Root>.<Ext>. Default for new file names: <SDFileName><AtomTypesFP>.<Ext>. The file type determines <Ext> value. The sdf, fpf, csv, and tsv <Ext> values are used for SD, FP, comma/semicolon, and tab delimited text files, respectively.This option is ignored for multiple input files.
Format of fingerprints vector string data in output SD, FP or CSV/TSV text file(s) specified by --output used during <AtomTypesCount> value of -m, --mode option. Possible values: ValuesString, IDsAndValuesString | IDsAndValuesPairsString | ValuesAndIDsString | ValuesAndIDsPairsString.
Default value during ArbitrarySize value of -e, --AtomTypesSetToUse option: IDsAndValuesString. Default value during FixedSize value of -e, --AtomTypesSetToUse option: ValuesString.
Example of SD file containing atom types fingerprints string data:
Example of FP file containing atom types fingerprints string data:
Example of CSV Text file atom types containing fingerprints string data:
Examples:
Location of working directory. Default: current directory.
To generate atomic invariants atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate functional class atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate E-state atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate E-state atom types count fingerprints of fixed size in vector string with IDsAndValues format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate E-state atom types bits fingerprints of fixed size in bit-vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of fixed size in vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of fixed size in vector string with IDsAndValues format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate MMFF94 atom types bits fingerprints of fixed size in bit-vector string format and create a SampleATFP.csv file containing sequential compound IDs along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing compound ID from molecule name line along with fingerprints vector strings data, type
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing compound IDs using specified data field along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing compound ID using combination of molecule name line and an explicit compound prefix along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing specific data fields columns along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create a SampleATFP.csv file containing common data fields columns along with fingerprints vector strings data, type:
To generate MMFF94 atom types count fingerprints of arbitrary size in vector string format and create SampleATFP.sdf, SampleATFP.fpf and SampleATFP.csv files containing all data fields columns in CSV file along with fingerprints vector strings data, type:
InfoFingerprintsFiles.pl, SimilarityMatricesFingerprints.pl, AtomNeighborhoodsFingerprints.pl, ExtendedConnectivityFingerprints.pl, MACCSKeysFingeprints.pl, PathLengthFingerprints.pl, TopologicalAtomPairsFingerprints.pl, TopologicalAtomTorsionsFingerprints.pl, TopologicalPharmacophoreAtomPairsFingerprints.pl, TopologicalPharmacophoreAtomTripletsFingerprints.pl
Copyright (C) 2024 Manish Sud. All rights reserved.
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.