Class BCUT

All Implemented Interfaces:
chemaxon.license.Licensable, Cloneable

@PublicAPI public class BCUT extends MolecularDescriptor implements chemaxon.license.Licensable
Implements BCUT descriptors. Calculates lowest and highest eigenvalues of the original Burden matrix and the three variant introduced by Pearlamn and Smith (ref: R. S. Pearlman and K.M. Smith: Novel Software Tools for Chemical Diversity, Perspectives in Drug Discovery and Design, 9/10/11: 339-353, 1998.) These three variants are: atom charge, atom polarizability and hydrogen bond acceptor/donor properties. The number of lowest and/or highest eigenvalues to be calculated are specified in the corresponding parameter configuration file.
Since:
JChem 2.3
  • Field Details

    • lowestEigenvalues

      protected float[][] lowestEigenvalues
    • highestEigenvalues

      protected float[][] highestEigenvalues
  • Constructor Details

    • BCUT

      public BCUT()
      Creates a new, empty BCUT descriptor.
    • BCUT

      public BCUT(BCUTParameters params)
      Creates a new instance according to the parameters.
      Parameters:
      params - configuration parameters
    • BCUT

      public BCUT(String params)
      Creates a new instance according to the parameters.
      Parameters:
      params - parameter settings
    • BCUT

      public BCUT(BCUT sd)
      Copy constructor. An identical copy of the BCUT passed is created. The old and the new instances share the same BCUTParameters object.
      Parameters:
      sd - BCUT descriptor to be copied
  • Method Details

    • clone

      public BCUT clone()
      Creates a new instance with identical internal state.
      Specified by:
      clone in class MolecularDescriptor
      Returns:
      the newly copied object
    • isLicensed

      public boolean isLicensed()
      Returns information about the licensing of the product.
      Specified by:
      isLicensed in interface chemaxon.license.Licensable
      Returns:
      true if the product is correctly licensed
    • setLicenseEnvironment

      public void setLicenseEnvironment(String env)
      Sets the license environment.
      Specified by:
      setLicenseEnvironment in interface chemaxon.license.Licensable
    • toData

      public byte[] toData()
      Converts a BCUT object into a byte array. This format can be reffered to as an "external representation" since it servers as the data format for storing BCUT descriptors in databases.
      Use the fromData() method to build the BCUT object from this "external" representation.
      Specified by:
      toData in class MolecularDescriptor
      Returns:
      byte array representation of the descriptor object
    • fromData

      public void fromData(byte[] dbRepr)
      Builds a BCUT descriptor from an external data format, created by a previous call to toData().
      Specified by:
      fromData in class MolecularDescriptor
      Parameters:
      dbRepr - "external" representation of a BCUT object
    • getName

      public String getName()
      Gets the name of the BCUT descriptor object. This name is not the same as the class name: nicer, and more meaningful for end-users too.
      Overrides:
      getName in class MolecularDescriptor
      Returns:
      the nice, external name for BCUT descriptor class objects
    • getShortName

      public String getShortName()
      Gets the short name of the descriptor.
      Overrides:
      getShortName in class MolecularDescriptor
      Returns:
      the short name used in text outputs (tables etc.)
    • setParameters

      public void setParameters(String parameters) throws MDParametersException
      Sets the parameters of an already created BCUT object.
      Specified by:
      setParameters in class MolecularDescriptor
      Parameters:
      parameters - parameter settings for the descriptor
      Throws:
      MDParametersException - any XML error
    • setParameters

      public void setParameters(MDParameters parameters) throws MDParametersException
      Sets the parameters of an already created BCUT object.
      Overrides:
      setParameters in class MolecularDescriptor
      Parameters:
      parameters - parameter settings for the descriptor
      Throws:
      MDParametersException - any XML error
    • getParametersClassName

      public String getParametersClassName()
      Gets the name of the parameters class corresponding to the descriptor.
      Overrides:
      getParametersClassName in class MolecularDescriptor
      Returns:
      the name of the parameters class
    • clear

      public void clear()
      Clears the descriptor, all values are set to zero.
    • getLowestEigenvalue

      public float getLowestEigenvalue(int desc, int index)
      Gets the specified lowest eigenvalue.
      Parameters:
      desc - the index of descriptor
      index - the index of one of the lowest eigenvalues to be retrieved (0 is the smallest).
      Returns:
      smallest 'index'-th eigenvalue
    • getHighestEigenvalue

      public float getHighestEigenvalue(int desc, int index)
      Gets the specified highest eigenvalue.
      Parameters:
      desc - the index of descriptor
      index - the index of one of the highest eigenvalues to be retrieved (0 is the largest)
      Returns:
      largest 'index'-th eigenvalue
    • fromString

      public final void fromString(String bcut) throws ParseException
      Builds a BCUT descriptor from its string representation created by toString().
      Specified by:
      fromString in class MolecularDescriptor
      Parameters:
      bcut - BCUT descriptor string
      Throws:
      ParseException
    • toString

      public final String toString()
      Converts the descriptor into a readable string. This is the default external text format of the BCUT descriptor, and it is also the format which is be stored in SDfiles. Lowest eigenvalues are printed first, and they are comma separated. Lowest and highest eigenvalue are separated by a semicolon, which is printed if there is at least one highest eigenvalue calculated (even if no lowest values are needed).
      Specified by:
      toString in class MolecularDescriptor
      Returns:
      string representation of the descriptor
    • toDecimalString

      public final String toDecimalString()
      Converts the BCUT descriptor into a tab separated string.
      Specified by:
      toDecimalString in class MolecularDescriptor
      Returns:
      string representation of the descriptor
    • toFloatArray

      public float[] toFloatArray()
      Creates the float array representation of a BCUT descriptor object.
      Specified by:
      toFloatArray in class MolecularDescriptor
      Returns:
      a float array of the descriptor values
    • fromFloatArray

      public void fromFloatArray(float[] descr)
      Builds a BCUT descriptor from its float array representation (generated by toFloatArray()). Typically use is hypothesis generation.
      Specified by:
      fromFloatArray in class MolecularDescriptor
      Parameters:
      descr - descriptor represented in a float array
    • generate

      public String[] generate(Molecule m) throws MDGeneratorException
      Creates the BCUT descriptor for the given Molecule. Calls the generator created by the corresponding BCUTParameters class.
      Overrides:
      generate in class MolecularDescriptor
      Returns:
      property names set in the molecule during generation
      Throws:
      MDGeneratorException - when failed to generate descriptor
    • getDissimilarityMetrics

      public String[] getDissimilarityMetrics()
      Gets the dissimilarity metric names introduced for this class of MolecularDescriptor.
      Specified by:
      getDissimilarityMetrics in class MolecularDescriptor
      Returns:
      the metrics array
    • getDefaultDissimilarityMetricThresholds

      public float[] getDefaultDissimilarityMetricThresholds()
      Gets the default dissimilarity threshold values for all dissimilarity metrics defined.
      Specified by:
      getDefaultDissimilarityMetricThresholds in class MolecularDescriptor
      Returns:
      array of dissimilarity threshold values
    • getEuclidean

      public final float getEuclidean(BCUT descr)
      Calculates the Euclidean distance. The dissimilarity coefficient returned ranges from 0 to MAX_FLOAT, this coefficient is not normalized.
      Parameters:
      descr - another descriptor from which the distance is measured
      Returns:
      dissimilarity coefficient
    • getWeightedEuclidean

      public final float getWeightedEuclidean(BCUT descr)
      Calculates the weighted Euclidean distance. Weights are taken from the associated BCUTParameters object.
      Parameters:
      descr - a descriptor from which the distance is measured
      Returns:
      dissimilarity coefficient
    • getDissimilarity

      public float getDissimilarity(MolecularDescriptor other)
      Calculates the dissimilarity ratio between two BCUT objects using the current default metric. Default metric is set in the corresponding BCUTParameters object by setCurrentParametrizedMetric( int metricIndex ). In the case of assymetric distances swapping the two descriptors can make big difference.
      Specified by:
      getDissimilarity in class MolecularDescriptor
      Parameters:
      other - a descriptor, to which the dissimilarity ratio is measured
      Returns:
      dissimilarity ratio
    • getDissimilarity

      public float getDissimilarity(MolecularDescriptor other, int parametrizedMetricIndex)
      Calculates the dissimilarity between two BCUT objects using the specified metric, apart from that it is the same as getDissimilarity( final MolecularDescriptor other ).
      Specified by:
      getDissimilarity in class MolecularDescriptor
      Parameters:
      other - a descriptor, to which the dissimilarity ratio is measured
      parametrizedMetricIndex - the index of the parametrized metric to used
      Returns:
      dissimilarity ratio
      See Also:
    • getAliasNames

      public List<String> getAliasNames()