ccpnmodel.ccpncore.lib.molecule package

Module Documentation here

Submodules

ccpnmodel.ccpncore.lib.molecule.Labeling module

Library functions for molecule labeling

ccpnmodel.ccpncore.lib.molecule.Labeling.chemAtomLabelFractions(project, labeling: str, ccpCode: str, atomName: str) dict[source]

get isotopeCode:percentage mapping for atom in ChemComp with given labeling

ccpnmodel.ccpncore.lib.molecule.Labeling.chemAtomPairLabelFractions(project, labeling: str, ccpCode: str, atomNamePair: Sequence) dict[source]

get isotopeCode:percentage mapping for atom pair in ChemComp with given labeling Assumes that atoms are in the same residue

ccpnmodel.ccpncore.lib.molecule.Labeling.molAtomLabelFractions(labeling: str, molResidue, atomName: str) dict[source]

get isotopeCode:percentage mapping for atom in molResidue, with given labeling Will use molecule specific labeling if one exists, otherwise general labeling scheme.

ccpnmodel.ccpncore.lib.molecule.Labeling.molAtomLabelPairFractions(labeling: str, molResiduePair: Sequence, atomNamePair: Sequence) dict[source]

get isotopeCode:percentage mapping for atom (molResidue, atomName) pair with given labeling Will use molecule specific labeling if one exists, otherwise general labeling scheme.

ccpnmodel.ccpncore.lib.molecule.Labeling.sampleChainLabeling(sample, chainCode: str) str[source]

Get labeling string for chain chainCode in sample If chainCode does not match a SampleComponent, look for unambiguous global labeling: Heuristics: If there is only one SampleComponent, use that labeling If all SampleComponents with explicit chainCodes have the same labeling, use that labeling

ccpnmodel.ccpncore.lib.molecule.MoleculeModify module

API (data storage) level functionality for creating and modifying molecules

ccpnmodel.ccpncore.lib.molecule.MoleculeModify.createMolecule(project, sequence: list, str, molType: str = 'protein', name: str = 'Molecule', startNumber: int = 1, isCyclic=False)[source]

Descrn: Makes Molecule for a given sequence

Inputs: Project,List of Words (ChemComp.CcpCode), Word (ChemComp.molType), String ( Ccp.Molecule.Molecule.name) Int (first MolResidue.seqCode)

Output: Molecule

ccpnmodel.ccpncore.lib.molecule.MoleculeModify.createMoleculeFromNef(project, name: str, sequence: Sequence[dict], defaultType: str = 'UNK') Molecule[source]

Create a Molecule from a sequence of NEF row dictionaries (or equivalent)

ccpnmodel.ccpncore.lib.molecule.MoleculeQuery module

API (data storage) level functionality for querying molecules

ccpnmodel.ccpncore.lib.molecule.MoleculeQuery.fetchStdResNameMap(project: MemopsRoot, reset: bool = False, debug: bool = False)[source]

fetch dict of {residueName:(molType,ccpCode)}, using cached value if present and not reset.

NBNB TBD Add naming variants from ChemComp naming systems