Pharmacophore queries

I would like to ask some questions related to the queries editing

1-Concerning the structure based pharmacophore example script supplied with DS:

when I use the shape query from the binding site script,the shape query retrieved could never get the ligand which was used to designate the binding site. Why ?

The same thing happend when I have aligned a group of ligands and created a shape query using all of them. Using this query,I could barely retrieve one or two ligands even if I set tolerance to low value.

2-I would like to have a script which can calculate the selectivity score based on capdiverse db.

The algorithm is used embedded in the ligand receptor pharmacophore generation in DS3,but the rules used to calculate it is not given in the manual even .I mean the way this value is calculated and the meaning of these values.

In my work ,I would like to extend the use of this scoring function to evaluate pharmacophores manually generated.

Thanks very much