Browse Source

rename to traceOnly

JonStargaryen 3 years ago
parent
commit
30d5b0ddb1

+ 1 - 1
src/extensions/anvil/prop.ts

@@ -77,7 +77,7 @@ export const MembraneOrientationProvider: CustomStructureProperty.Provider<Membr
 
 async function computeAnvil(ctx: CustomProperty.Context, data: Structure, props: Partial<ANVILProps>): Promise<MembraneOrientation> {
     // can't get away with the default 92 points here
-    await AccessibleSurfaceAreaProvider.attach(ctx, data, { probeSize: 4.0, alphaOnly: true, numberOfSpherePoints: 184 });
+    await AccessibleSurfaceAreaProvider.attach(ctx, data, { probeSize: 4.0, traceOnly: true, numberOfSpherePoints: 184 });
     const p = { ...PD.getDefaultValues(ANVILParams), ...props };
     return await computeANVIL(data, p).runInContext(ctx.runtime);
 }

+ 3 - 3
src/mol-model-props/computed/accessible-surface-area/shrake-rupley.ts

@@ -19,7 +19,7 @@ export const ShrakeRupleyComputationParams = {
     probeSize: PD.Numeric(1.4, { min: 0.1, max: 4, step: 0.01 }, { description: 'Corresponds to the size of a water molecule: 1.4 (original paper), 1.5 (occassionally used)' }),
     // buriedRasaThreshold: PD.Numeric(0.16, { min: 0.0, max: 1.0 }, { description: 'below this cutoff of relative accessible surface area a residue will be considered buried - see: Rost B, Sander C: Conservation and prediction of solvent accessibility in protein families. Proteins 1994.' }),
     nonPolymer: PD.Boolean(false, { description: 'Include non-polymer atoms as occluders.' }),
-    alphaOnly: PD.Boolean(false, { description: 'Compute only using alpha-carbons, if true increase probeSize accordingly (e.g., 4 A).' })
+    traceOnly: PD.Boolean(false, { description: 'Compute only using alpha-carbons, if true increase probeSize accordingly (e.g., 4 A).' })
 };
 export type ShrakeRupleyComputationParams = typeof ShrakeRupleyComputationParams
 export type ShrakeRupleyComputationProps = PD.Values<ShrakeRupleyComputationParams>
@@ -58,13 +58,13 @@ namespace AccessibleSurfaceArea {
 
     function initialize(structure: Structure, props: ShrakeRupleyComputationProps): ShrakeRupleyContext {
         const { elementCount, atomicResidueCount } = structure;
-        const { probeSize, nonPolymer, alphaOnly, numberOfSpherePoints } = props;
+        const { probeSize, nonPolymer, traceOnly, numberOfSpherePoints } = props;
 
         return {
             structure,
             probeSize,
             nonPolymer,
-            alphaOnly,
+            traceOnly,
             spherePoints: generateSpherePoints(numberOfSpherePoints),
             scalingConstant: 4.0 * Math.PI / numberOfSpherePoints,
             maxLookupRadius: 2 * props.probeSize + 2 * VdWLookup[2], // 2x probe size + 2x largest VdW

+ 1 - 1
src/mol-model-props/computed/accessible-surface-area/shrake-rupley/common.ts

@@ -12,7 +12,7 @@ export interface ShrakeRupleyContext {
     spherePoints: Vec3[],
     probeSize: number,
     nonPolymer: boolean,
-    alphaOnly: boolean,
+    traceOnly: boolean,
     scalingConstant: number,
     maxLookupRadius: number,
     atomRadiusType: Int8Array,

+ 1 - 1
src/mol-model-props/computed/accessible-surface-area/shrake-rupley/radii.ts

@@ -53,7 +53,7 @@ export function assignRadiusForHeavyAtoms(ctx: ShrakeRupleyContext) {
             const atomId = label_atom_id(l);
             const moleculeType = getElementMoleculeType(unit, eI);
             // skip water and optionally non-polymer groups
-            if (moleculeType === MoleculeType.Water || (!ctx.nonPolymer && !isPolymer(moleculeType)) || (ctx.alphaOnly && (atomId !== 'CA' || !MaxAsa[label_comp_id(l)]))) {
+            if (moleculeType === MoleculeType.Water || (!ctx.nonPolymer && !isPolymer(moleculeType)) || (ctx.traceOnly && (atomId !== 'CA' || !MaxAsa[label_comp_id(l)]))) {
                 atomRadiusType[mj] = VdWLookup[0];
                 serialResidueIndex[mj] = -1;
                 continue;