Skip to main content

findSimilar()

findSimilar(column, molecule?, settings?): Promise<DataFrame | null>

Defined in: src/chem.ts:726

Computes similarity scores for molecules in the input vector based on a preferred similarity score. See example: https://public.datagrok.ai/js/samples/domains/chem/similarity-scoring-sorted

Parameters

ParameterTypeDefault valueDescription
columnColumnundefinedColumn with molecules to search in
moleculestring''Reference molecule in one of formats supported by RDKit: smiles, cxsmiles, molblock, v3Kmolblock, and inchi
settings{ cutoff: number; limit: number; }...Properties for the similarity function
settings.cutoffnumber0.0Would drop molecules which score is lower than cutoff
settings.limitnumberNumber.MAX_VALUEWould return top limit molecules based on the score

Returns

Promise<DataFrame | null>

  • DataFrame with 3 columns:
    • molecule: original molecules string representation from the input column
    • score: similarity scores within the range from 0.0 to 1.0; DataFrame is sorted descending by this column
    • index: indices of the molecules in the original input column

Async