Skip to content
Snippets Groups Projects
Commit e36d483f authored by David Sehnal's avatar David Sehnal
Browse files

model-server: added residueSurroundings query

parent 9de16699
No related branches found
No related tags found
No related merge requests found
......@@ -126,6 +126,16 @@ const QueryMap = {
},
params: [ AtomSiteTestParams, RadiusParam ]
}),
'residueSurroundings': Q<{ atom_site: AtomSiteSchema, radius: number }>({
niceName: 'Residue Surroundings',
description: 'Identifies all residues within the given radius from the source residue.',
query(p) {
const tests = getAtomsTests(p.atom_site);
const center = Queries.combinators.merge(tests.map(test => Queries.generators.atoms(test)));
return Queries.modifiers.includeSurroundings(center, { radius: p.radius, wholeResidues: true });
},
params: [ AtomSiteTestParams, RadiusParam ]
})
};
export type QueryName = keyof typeof QueryMap
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment