Hello everyone,

i want to calculate the tanimoto similarity from a bitstring of 1's und 0's.


Im getting deffierent resulst for example:


for the RDKIT tanimoto I'm reading:
fingerprint= GenMACCSKeys(molec[0])


for the "own" tanimoto function im reading the key like:
fingerprint= GenMACCSKeys(molec[0])*.ToBitString()    *         so, a
ToBitString is added on the line

If im comparing them im using:

RDKIT function:

DataStructs.TanimotoSimilarity(FP1,FP2)

"own"n function :

    for i in range(len(FP1)):
        if FP1[i]==1.0 and FP2[i]==1.0:
            c+=1

    print float(c)/(len(FP1) + len(FP2) - c)

So I'm just count al 1 Bits at the same position und FP1 und FP 2 to get
the c
and then im calculating:   c / (a+b-c)


and I#m Getting these values:

0.00602409638554  From "own" function
2  # counts of c
0.0333333333333 from RDKit

Somebody knows what I'm doing wrong?

best,

alex
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Rdkit-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to