mmCIF File Format¶
The mmCIF file format is a container for structural entities provided by the
PDB. Here we describe how to load those files and how to deal with information
provided above the legacy PDB format (MMCifInfo
,
MMCifInfoCitation
, MMCifInfoTransOp
,
MMCifInfoBioUnit
, MMCifInfoStructDetails
,
MMCifInfoObsolete
, MMCifInfoStructRef
,
MMCifInfoStructRefSeq
, MMCifInfoStructRefSeqDif
,
MMCifInfoRevisions
, MMCifInfoEntityBranchLink
).
Loading mmCIF Files¶
- LoadMMCIF(filename, fault_tolerant=None, calpha_only=None, profile='DEFAULT', remote=False, seqres=False, info=False)¶
Load a mmCIF file and return one or more entities. Several options allow to customize the exact behaviour of the mmCIF import. For more information on these options, see IO Profiles for entity importer.
Residues are flagged as ligand if they are not waters nor covered by an
entity_poly
record (ie. they are non-polymer entities inpdbx_entity_nonpoly
). Note that all residues except waters will be flagged as ligands ifseqres=False
(the default).- Parameters:
filename (
str
) – File to be loadedfault_tolerant (
bool
) – Enable/disable fault-tolerant import. If set, overrides the value ofIOProfile.fault_tolerant
.calpha_only (
bool
) – When set to true, forces the importer to only load atoms named CA. If set, overrides the value ofIOProfile.calpha_only
.profile (
str
/ost.io.IOProfile
) – Aggregation of flags and algorithms to control import and processing of molecular structures. Can either be astr
specifying one of the default profiles [‘DEFAULT’, ‘SLOPPY’, ‘CHARMM’, ‘STRICT’] or an actual object of typeost.io.IOProfile
. If astr
defines a default profile,IOProfile.processor
is set toost.conop.RuleBasedProcessor
with the currently setost.conop.CompoundLib
available asost.conop.GetDefaultLib()
. If noost.conop.CompoundLib
is available,ost.conop.HeuristicProcessor
is used instead. See IO Profiles for entity importer for more info.remote (
bool
) – If set to True, the method tries to load the pdb from the remote pdb repository www.pdb.org. The filename is then interpreted as the pdb id.seqres (
bool
) – Whether to return SEQRES records. If True, aSequenceList
object is returned as the second item. The sequences in the list are named according to the mmCIF chain name. This feature requires a defaultcompound library
to be defined and accessible viaGetDefaultLib()
. One letter codes of non standard compounds are set to X otherwise.info (
bool
) – Whether to return an info container with the other output. If True, aMMCifInfo
object is returned as last item.
- Return type:
EntityHandle
(or tuple if seqres or info are True).- Raises:
IOException
if the import fails due to an erroneous or non-existent file.
Categories Available¶
The following categories of a mmCIF file are considered by the reader:
atom_site
: Used to build theEntityHandle
entity
: Involved in settingChainType
of chainsentity_poly
: Involved in settingChainType
of chainscitation
: Goes intoMMCifInfoCitation
citation_author
: Goes intoMMCifInfoCitation
refine
: Goes intoMMCifInfo
asresolution
,r_free
andr_work
.pdbx_struct_assembly
: Used forMMCifInfoBioUnit
.pdbx_struct_assembly_gen
: Used forMMCifInfoBioUnit
.pdbx_struct_oper_list
: Used forMMCifInfoBioUnit
.struct
: Details about a structure, stored inMMCifInfoStructDetails
.struct_conf
: Stores secondary structure information (practically helices) in theEntityHandle
struct_sheet_range
: Stores secondary structure information for sheets in theEntityHandle
pdbx_database_PDB_obs_spr
: Verbose information on obsoleted/ superseded entries, stored inMMCifInfoObsolete
struct_ref
stored inMMCifInfoStructRef
struct_ref_seq
stored inMMCifInfoStructRefSeqDif
struct_ref_seq_dif
stored inMMCifInfoStructRefDif
database_pdb_rev
(mmCIF dictionary version < 5) stored inMMCifInfoRevisions
pdbx_audit_revision_history
andpdbx_audit_revision_details
(mmCIF dictionary version >= 5) used to fillMMCifInfoRevisions
pdbx_entity_branch
andpdbx_entity_branch_link
used forMMCifInfoEntityBranchLink
, a list of links is available byGetEntityBranchLinks()
andGetEntityBranchByChain()
Notes:
Structures in mmCIF format can have two chain names. The “new” chain name extracted from
atom_site.label_asym_id
is used to name the chains in theEntityHandle
. The “old” (author provided) chain name is extracted fromatom_site.auth_asym_id
for the first atom of the chain. It is added as string property named “pdb_auth_chain_name” to theChainHandle
. The mapping is also stored inMMCifInfo
asGetMMCifPDBChainTr()
andGetPDBMMCifChainTr()
if a non-empty SEQRES record exists for that chain (this should exclude ligands and water).Molecular entities in mmCIF are identified by an
entity.id
, which is extracted fromatom_site.label_entity_id
for the first atom of the chain. It is added as string property named “entity_id” to theChainHandle
. Each chain is mapped to an ID inMMCifInfo
asGetMMCifEntityIdTr()
.For more complex mappings, such as ligands which may be in a same “old” chain as the protein chain but are represented in a separate “new” chain in mmCIF, we also store
string properties
on a per-residue level. For mmCIF files from the PDB, there is a unique mapping between (“label_asym_id”, “label_seq_id”) and (“auth_asym_id”, “auth_seq_id”, “pdbx_PDB_ins_code”). The following data items are available:atom_site.label_asym_id
:residue.chain.name
atom_site.label_seq_id
:residue.GetStringProp("resnum")
(this is the same asresidue.number
for residues in polymer chains. However, for ligandsresidue.number
is unset in mmCIF, but it is set to 1 by openstructure.)atom_site.label_entity_id
:residue.GetStringProp("entity_id")
atom_site.auth_asym_id
:residue.GetStringProp("pdb_auth_chain_name")
atom_site.auth_seq_id
:residue.GetStringProp("pdb_auth_resnum")
atom_site.pdbx_PDB_ins_code
:residue.GetStringProp("pdb_auth_ins_code")
Missing values in the aforementioned data items will be denoted as
.
or?
.
Info Classes¶
Information from mmCIF files that goes beyond structural data, is kept in a
special container, the MMCifInfo
class. Here is a detailed description
of the annotation available.
- class MMCifInfo¶
This is the container for all bits of non-molecular data pulled from a mmCIF file.
- citations¶
Stores a list of citations (
MMCifInfoCitation
).Also available as
GetCitations()
.
- biounits¶
Stores a list of biounits (
MMCifInfoBioUnit
).Also available as
GetBioUnits()
.
- method¶
Stores the experimental method used to create the structure (
exptl.method
).Also available as
GetMethod()
. May also be modified bySetMethod()
.
- resolution¶
Stores the resolution of the crystal structure. Set to 0 if no value in loaded mmCIF file.
Also available as
GetResolution()
. May also be modified bySetResolution()
.
- r_free¶
Stores the R-free value of the crystal structure. Set to 0 if no value in loaded mmCIF file.
Also available as
GetRFree()
. May also be modified bySetRFree()
.
- r_work¶
Stores the R-work value of the crystal structure. Set to 0 if no value in loaded mmCIF file.
Also available as
GetRWork()
. May also be modified bySetRWork()
.
- operations¶
Stores the operations needed to transform a crystal structure into a bio unit.
Also available as
GetOperations()
. May also be modified byAddOperation()
.
- struct_details¶
Stores details about the structure in a
MMCifInfoStructDetails
object.Also available as
GetStructDetails()
. May also be modified bySetStructDetails()
.
- struct_refs¶
Lists all links to external databases in the mmCIF file.
- revisions¶
Stores a simple history of a PDB entry.
Also available as
GetRevisions()
. May be extended byAddRevision()
.- Type:
- obsolete¶
Stores information about obsoleted / superseded entries.
Also available as
GetObsoleteInfo()
. May also be modified bySetObsoleteInfo()
.- Type:
- AddCitation(citation)¶
Add a citation to the citation list of an info object.
- Parameters:
citation (
MMCifInfoCitation
) – Citation to be added.
- AddAuthorsToCitation(id, authors, fault_tolerant=False)¶
Adds a list of authors to a specific citation.
- Parameters:
id (
str
) – Identifier of the citation.authors (
StringList
) – List of authors.fault_tolerant (
bool
) – Logs a warning if id is not found and proceeds without setting anything if set to True. Raises otherwise.
- AddBioUnit(biounit)¶
Add a bio unit to the bio unit list of an info object. If the
id
ofbiounit
already exists in the set of assemblies, both will be merged. This means thatchain
andoperations
lists will be concatenated and the interval lists (operationsintervalls
,chainintervalls
) will be updated.- Parameters:
biounit (
MMCifInfoBioUnit
) – Bio unit to be added.
- SetResolution(resolution)¶
See
resolution
- GetResolution()¶
See
resolution
- AddOperation(operation)¶
See
operations
- GetOperations()¶
See
operations
- SetStructDetails(details)¶
See
struct_details
- GetStructDetails()¶
- AddMMCifPDBChainTr(cif_chain_id, pdb_chain_id)¶
Set up a translation for a certain mmCIF chain name to the traditional PDB chain name.
- Parameters:
cif_chain_id (
str
) – atom_site.label_asym_idpdb_chain_id (
str
) – atom_site.auth_asym_id
- GetMMCifPDBChainTr(cif_chain_id)¶
Get the translation of a certain mmCIF chain name to the traditional PDB chain name.
- Parameters:
cif_chain_id (
str
) – atom_site.label_asym_id- Returns:
atom_site.auth_asym_id as
str
(empty if no mapping)
- AddPDBMMCifChainTr(pdb_chain_id, cif_chain_id)¶
Set up a translation for a certain PDB chain name to the mmCIF chain name.
- Parameters:
pdb_chain_id (
str
) – atom_site.auth_asym_idcif_chain_id (
str
) – atom_site.label_asym_id
- GetPDBMMCifChainTr(pdb_chain_id)¶
Get the translation of a certain PDB chain name to the mmCIF chain name.
- Parameters:
pdb_chain_id (
str
) – atom_site.auth_asym_id- Returns:
atom_site.label_asym_id as
str
(empty if no mapping)
- AddMMCifEntityIdTr(cif_chain_id, entity_id)¶
Set up a translation for a certain mmCIF chain name to the mmCIF entity ID.
- Parameters:
cif_chain_id (
str
) – atom_site.label_asym_identity_id (
str
) – atom_site.label_entity_id
- GetMMCifEntityIdTr(cif_chain_id)¶
Get the translation of a certain mmCIF chain name to the mmCIF entity ID.
- Parameters:
cif_chain_id (
str
) – atom_site.label_asym_id- Returns:
atom_site.label_entity_id as
str
(empty if no mapping)
- AddRevision(num, date, status, major=-1, minor=-1)¶
Add a new iteration to the revision history. See
MMCifInfoRevisions.AddRevision()
.
- SetRevisionsDateOriginal(date)¶
Set the date, when this entry first entered the PDB. Ignored if it was set in the past. See
MMCifInfoRevisions.SetDateOriginal()
.
- GetEntityBranchLinks()¶
Get bond information for branched entities. Returns all
MMCifInfoEntityBranchLink
objects in one list. Chain and residue information is available by the storedAtomHandles
of each entry.- Returns:
list
ofMMCifInfoEntityBranchLink
- GetEntityBranchByChain(chain_name)¶
Get bond information for chains with branched entities. Returns all
MMCifInfoEntityBranchLink
objects in one list if chain is a branched entity, an empty list otherwise.- Parameters:
chain_name (
str
) – Chain name to check for branch links- Returns:
list
ofMMCifInfoEntityBranchLink
- AddEntityBranchLink(chain_name, atom1, atom2, bond_order)¶
Add bond information for a branched entity.
- Parameters:
chain_name (
str
) – Chain the bond belongs toatom1 (
AtomHandle
) – First atom of the bondatom2 (
AtomHandle
) – Second atom of the bondbond_order (
int
) – Bond order (e.g. 1=single, 2=double, 3=triple)
- Returns:
Nothing
- GetEntityBranchChainNames()¶
Get a list of chain names which contain branched entities.
- Returns:
list
ofstr
- GetEntityBranchChains()¶
Get a list of chains which contain branched entities.
- Returns:
list
ofChainHandle
- ConnectBranchLinks()¶
Establish all bonds stored for branched entities.
- class MMCifInfoCitation¶
This stores citation information from an input file.
- id¶
Stores an internal identifier for a citation. If not provided, resembles an empty string.
Also available as
GetID()
. May also be modified bySetID()
.
- cas¶
Stores a Chemical Abstract Service identifier if available. If not provided, resembles an empty string.
Also available as
GetCAS()
. May also be modified bySetCas()
.
- isbn¶
Stores the ISBN code, presumably for cited books. If not provided, resembles an empty string.
Also available as
GetISBN()
. May also be modified bySetISBN()
.
- published_in¶
Stores the book or journal title of a publication. Should take the full title, no abbreviations. If not provided, resembles an empty string.
Also available as
GetPublishedIn()
. May also be modified bySetPublishedIn()
.
- volume¶
Supposed to store volume information for journals. Since the volume number is not always a simple integer, it is stored as a string. If not provided, resembles an empty string.
Also available as
GetVolume()
. May also be modified bySetVolume()
.
- page_first¶
Stores the first page of a publication. Since the page numbers are not always a simple integers, they are stored as strings. If not provided, resembles empty strings.
Also available as
GetPageFirst()
. May also be modified bySetPageFirst()
.
- page_last¶
Stores the last page of a publication. Since the page numbers are not always a simple integers, they are stored as strings. If not provided, resembles empty strings.
Also available as
GetPageLast()
. May also be modified bySetPageLast()
.
- doi¶
Stores the Document Object Identifier as used by doi.org for a cited document. If not provided, resembles an empty string.
Also available as
GetDOI()
. May also be modified bySetDOI()
.
- pubmed¶
Stores the PubMed accession number. If not provided, is set to 0.
Also available as
GetPubMed()
. May also be modified bySetPubmed()
.
- year¶
Stores the publication year. If not provided, is set to 0.
Also available as
GetYear()
. May also be modified bySetYear()
.
- title¶
Stores a title. If not provided, is set to an empty string.
Also available as
GetTitle()
. May also be modified bySetTitle()
.
- book_publisher¶
Name of publisher of the citation, relevant for books and book chapters.
Also available as
GetBookPublisher()
andSetBookPublisher()
.
- book_publisher_city¶
City of the publisher of the citation, relevant for books and book chapters.
Also available as
GetBookPublisherCity()
andSetBookPublisherCity()
.
- citation_type¶
Defines where a citation was published. Either journal, book or unknown.
Also available as
GetCitationType()
. May also be modified bySetCitationType()
with values fromMMCifInfoCType
. For conveinience settersSetCitationTypeJournal()
,SetCitationTypeBook()
andSetCitationTypeUnknown()
exist.For checking the type of a citation,
IsCitationTypeJournal()
,IsCitationTypeBook()
andIsCitationTypeUnknown()
can be used.
- authors¶
Stores a
StringList
of authors.Also available as
GetAuthorList()
. May also be modified bySetAuthorList()
.
- GetPublishedIn()¶
See
published_in
- SetPublishedIn(title)¶
See
published_in
- GetPageFirst()¶
See
page_first
- SetPageFirst(first)¶
See
page_first
- GetBookPublisher()¶
See
book_publisher
- SetBookPublisher()¶
See
book_publisher
- GetBookPublisherCity()¶
- SetBookPublisherCity()¶
- GetCitationType()¶
See
citation_type
- SetCitationType(publication_type)¶
See
citation_type
- SetCitationTypeJournal()¶
See
citation_type
- SetCitationTypeBook()¶
See
citation_type
- SetCitationTypeUnknown()¶
See
citation_type
- IsCitationTypeJournal()¶
See
citation_type
- IsCitationTypeBook()¶
See
citation_type
- IsCitationTypeUnknown()¶
See
citation_type
- class MMCifInfoTransOp¶
This stores operations needed to transform an
EntityHandle
into a bio unit.- id¶
A unique identifier. If not provided, resembles an empty string.
- type¶
Describes the operation. If not provided, resembles an empty string.
Also available as
GetType()
. May also be modified bySetType()
.
- translation¶
The translational vector. Also available as
GetVector()
. May also bemodified by
SetVector()
.
- rotation¶
The rotational matrix. Also available as
GetMatrix()
. May also bemodified by
SetMatrix()
.
- GetVector()¶
See
translation
- SetVector(x, y, z)¶
See
translation
- class MMCifInfoBioUnit¶
This stores information how a structure is to be assembled to form the bio unit.
- id¶
The id of a bio unit as given by the original mmCIF file.
Also available as
GetID()
. May also be modified bySetID()
.- Type:
str
- details¶
Special aspects of the biological assembly. If not provided, resembles an empty string.
Also available as
GetDetails()
. May also be modified bySetDetails()
.
- method_details¶
Details about the method used to determine this biological assembly.
Also available as
GetMethodDetails()
. May also be modified bySetMethodDetails()
.
- chains¶
Chains involved in this bio unit. If not provided, resembles an empty list.
Also available as
GetChainList()
. May also be modified byAddChain()
orSetChainList()
.
- chainintervals¶
List of intervals on the chain list. Needed if there a several sets of chains and transformations to create the bio unit. Comes as a list of tuples. First component is the start, second is the right border of the interval.
Also available as
GetChainIntervalList()
. Is automatically modified byAddChain()
,SetChainList()
andMMCifInfo.AddBioUnit()
.
- operations¶
Translations and rotations needed to create the bio unit. Filled with objects of class
MMCifInfoTransOp
.Also available as
GetOperations()
. May be modified byAddOperations()
- operationsintervalls¶
List of intervals on the operations list. Needed if there a several sets of chains and transformations to create the bio unit. Comes as a list of tuples. First component is the start, second is the right border of the interval.
Also available as
GetOperationsIntervalList()
. Is automatically modified byAddOperations()
andMMCifInfo.AddBioUnit()
.
- GetMethodDetails()¶
See
method_details
- SetMethodDetails(details)¶
See
method_details
- SetChainList(chains)¶
See
chains
, also resetschainintervalls
to contain only one interval enclosing the whole chain list.- Parameters:
chains (
StringList
) – List of chain names.
- AddChain(chain name)¶
See
chains
, also extends the right border of the last entry inchainintervalls
.
- GetChainIntervalList()¶
See
chainintervals
- GetOperations()¶
See
operations
- AddOperations(list of operations)¶
See
operations
, also extends the right border of the last entry inoperationsintervalls
.
- GetOperationsIntervalList()¶
- PDBize(asu, seqres=None, min_polymer_size=None, transformation=False, peptide_min_size=10, nucleicacid_min_size=10, saccharide_min_size=10)¶
Returns the biological assembly (bio unit) for an entity. The new entity created is well suited to be saved as a PDB file. Therefore the function tries to meet the requirements of single-character chain names. The following measures are taken.
All ligands are put into one chain (_)
Water is put into one chain (-)
Each polymer gets its own chain, named A-Z 0-9 a-z.
The description of non-polymer chains will be put into a generic string property called description on the residue level.
Ligands that resemble a polymer but have less than min_polymer_size / peptide_min_size / nucleicacid_min_size / saccharide_min_size residues are assigned the same numeric residue number. The residues are distinguished by insertion code.
Sometimes bio units exceed the coordinate system storable in a PDB file. In that case, the box around the entity will be aligned to the lower left corner of the coordinate system.
Since this function is at the moment mainly used to create biounits from mmCIF files to be saved as PDBs, the function assumes that the
ChainType
properties are set correctly. For a more mmCIF-style of doing things read this: Biounits- Parameters:
asu (
EntityHandle
) – Asymmetric unit to work on. Should be created from a mmCIF file.seqres (
SequenceList
) – If set to a valid sequence list, the length of the seqres records will be used to determine if a certain chain has the minimally required length.min_polymer_size (int) – The minimal number of residues a polymer needs to get its own chain. Everything below that number will be sorted into the ligand chain. Overrides peptide_min_size, nucleicacid_min_size and saccharide_min_size if set to a value different than None.
transformation (
bool
) – If set, return the transformation matrix used to move the bounding box of the bio unit to the lower left corner.peptide_min_size (
int
) – Minimal size to get an individual chain for a polypeptide. Is overridden by min_polymer_size.nucleicacid_min_size (
int
) – Minimal size to get an individual chain for a polynucleotide. Is overridden by min_polymer_size.saccharide_min_size (
int
) – Minimal size to get an individual chain for an oligosaccharide or polysaccharide. Is overridden by min_polymer_size.
- class MMCifInfoStructDetails¶
Holds details about the structure.
- entry_id¶
Identifier for a curtain data block. If not provided, resembles an empty string.
Also available as
GetEntryID()
. May also be modified bySetEntryID()
.
- title¶
Set a title for the structure.
Also available as
GetTitle()
. May also be modified bySetTitle()
.
- casp_flag¶
Tells whether this structure was a target in some competition.
Also available as
GetCASPFlag()
. May also be modified bySetCASPFlag()
.
- descriptor¶
Descriptor for an NDB structure or the unstructured content of a PDB COMPND record.
Also available as
GetDescriptor()
. May also be modified bySetDescriptor()
.
- mass_method¶
Method used to determine the molecular weight.
Also available as
GetMassMethod()
. May also be modified bySetMassMethod()
.
- model_details¶
Details about how the structure was determined.
Also available as
GetModelDetails()
. May also be modified bySetModelDetails()
.
- model_type_details¶
Details about how the type of the structure was determined.
Also available as
GetModelTypeDetails()
. May also be modified bySetModelTypeDetails()
.
- GetDescriptor()¶
See
descriptor
- SetDescriptor(descriptor)¶
See
descriptor
- GetMassMethod()¶
See
mass_method
- SetMassMethod(method)¶
See
mass_method
- GetModelDetails()¶
See
model_details
- SetModelDetails(details)¶
See
model_details
- GetModelTypeDetails()¶
- SetModelTypeDetails(details)¶
- class MMCifInfoObsolete¶
- Holds details on obsolete / superseded structures. The data is
available both in the obsolete and in the replacement entries.
- id¶
Type of change. Either Obsolete or Supersede. Returns a string starting upper case. Has to be set via
OBSLTE
orSPRSDE
.
- pdb_id¶
ID of the replacing entry.
Also available as
GetPDBID()
. May also be modified bySetPDBID()
.
- replace_pdb_id¶
ID of the replaced entry.
Also available as
GetReplacedPDBID()
. May also be modified bySetReplacedPDBID()
.
- GetReplacedPDBID()¶
See
replace_pdb_id
- SetReplacedPDBID(descriptor)¶
See
replace_pdb_id
- class MMCifInfoStructRef¶
Holds the information of the struct_ref category. The category describes the link of polymers in the mmCIF file to sequences stored in external databases such as UniProt. The related categories
struct_ref_seq
andstruct_ref_seq_dif
also list differences between the sequences of the deposited structure and the sequences in the database. Two prominent examples of such differences are point mutations and/or expression tags.- db_name¶
Name of the external database, for example UNP for UniProt.
- Type:
str
- db_access¶
Alternative accession code for the sequence in the database pointed to by
db_name
.- Type:
str
- GetAlignedSeq(name)¶
Returns the aligned sequence for the given name, None if the sequence does not exist.
- aligned_seqs¶
List of aligned sequences (all entries of the struct_ref_seq category mapping to this struct_ref).
- class MMCifInfoStructRefSeq¶
An aligned range of residues between a sequence in a reference database and the deposited sequence.
- align_id¶
Uniquely identifies every struct_ref_seq item in the mmCIF file.
- Type:
str
- seq_begin¶
- seq_end¶
The starting point (1-based) and end point of the aligned range in the deposited sequence, respectively.
- Type:
int
- db_begin¶
- db_end¶
The starting point (1-based) and end point of the aligned range in the database sequence, respectively.
- Type:
int
- difs¶
List of differences between the deposited sequence and the sequence in the database.
- chain_name¶
Chain name of the polymer in the mmCIF file.
- class MMCifInfoStructRefSeqDif¶
A particular difference between the deposited sequence and the sequence in the database.
- rnum¶
The residue number (1-based) of the residue in the deposited sequence
- Type:
int
- details¶
A textual description of the difference, e.g. point mutation, expression tag, purification artifact.
- Type:
str
- class MMCifInfoRevisions¶
Revision history of a PDB entry. If you find a ‘?’ somewhere, this means ‘not set’.
- date_original¶
The date when this entry was seen in PDB for the very first time. This is not necessarily the release date. Expected format ‘yyyy-mm-dd’.
- Type:
str
- first_release¶
Index + 1 of the revision releasing this entry. If the value is 0, was not set yet. Set first time we encounter a
GetStatus()
value of “full release” (mmCIF versions < 5) or “Initial release” (current mmCIF).- Type:
int
- AddRevision(num, date, status, major=-1, minor=-1)¶
Add a new iteration to the history.
- Parameters:
num (
int
) – SeeGetNum()
date (
str
) – SeeGetDate()
status (
str
) – SeeGetStatus()
major (
int
) – SeeGetMajor()
minor (
int
) – SeeGetMinor()
- Raises:
Exception if num is <= the last added iteration.
- GetSize()¶
- Returns:
Number of revisions (valid revision indices are in [0, number-1]).
- Return type:
int
- GetDate(i)¶
- Parameters:
i (
int
) – Index of revision- Returns:
Date the PDB revision took place. Expected format ‘yyyy-mm-dd’.
- Return type:
str
- Raises:
Exception if i out of bounds.
- GetNum(i)¶
- Parameters:
i (
int
) – Index of revision- Returns:
Unique identifier of revision (assigned in increasing order)
- Return type:
int
- Raises:
Exception if i out of bounds.
- GetStatus(i)¶
- Parameters:
i (
int
) – Index of revision- Returns:
The status of this revision.
- Return type:
str
- Raises:
Exception if i out of bounds.
- GetMajor(i)¶
- Parameters:
i (
int
) – Index of revision- Returns:
The major version of this revision (-1 if not set).
- Return type:
int
- Raises:
Exception if i out of bounds.
- GetMinor(i)¶
- Parameters:
i (
int
) – Index of revision- Returns:
The minor version of this revision (-1 if not set).
- Return type:
int
- Raises:
Exception if i out of bounds.
- GetLastDate()¶
- Returns:
Date of the latest revision (‘?’ if no revision set).
- Return type:
str
- GetLastMajor()¶
- Returns:
Major version of the latest revision (-1 if not set).
- Return type:
int
- GetLastMinor()¶
- Returns:
Minor version of the latest revision (-1 if not set).
- Return type:
int
- SetDateOriginal(date)¶
- GetDateOriginal()¶
See
date_original
- GetFirstRelease()¶
See
first_release
- class MMCifInfoEntityBranchLink¶
Data from
pdbx_entity_branch
, most specificallypdbx_entity_branch_link
. That is connectivity information for branched entities, e.g. carbohydrates/ oligosaccharides.Conop Processors
can not easily connect them so we use this information inLoadMMCIF()
to do that.- atom1¶
The first atom of the bond. Corresponds to
entity_branch_link.atom_id_1
,entity_branch_link.comp_id_1
andentity_branch_link.entity_branch_list_num_1
. Also available viaGetAtom1()
andSetAtom1()
.- Type:
- atom2¶
The second atom of the bond. Corresponds to
entity_branch_link.atom_id_2
,entity_branch_link.comp_id_2
andentity_branch_link.entity_branch_list_num_2
. Also available viaGetAtom2()
andSetAtom2()
.- Type:
- bond_order¶
Order of a bond (e.g. 1=single, 2=double, 3=triple). Corresponds to
entity_branch_link.value_order
. Also available viaGetBondOrder()
andSetBondOrder()
.- Type:
int
- ConnectBranchLink(editor)¶
Establish a bond between
atom1
andatom2
of aMMCifInfoEntityBranchLink
.- Parameters:
editor (
XCSEditor
) – The editor instance to call for connecting the atoms.- Returns:
Nothing
- GetBondOrder()¶
See
bond_order
- SetBondOrder()¶
See
bond_order
Biounits¶
Biological assemblies, i.e. biounits, are an integral part of mmCIF files and
their construction is fully defined in MMCifInfoBioUnit
.
MMCifInfoBioUnit.PDBize()
provides one possibility to construct such biounits
with compatibility with the PDB format in mind. That is single character chain
names, dumping all ligands in one chain etc. For a more mmCIF-style way of
constructing biounits, check out ost.mol.alg.CreateBU()
in the
ost.mol.alg module.