Skip to content

Commit

Permalink
Merge pull request #198 from NatureGeorge/fix_alt_aa_seq
Browse files Browse the repository at this point in the history
remove ligand and alt res within chain
  • Loading branch information
martin-steinegger authored Nov 9, 2023
2 parents 9a13e2d + c54dce5 commit 0c32b3b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/strucclustutils/GemmiWrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ void GemmiWrapper::updateStructure(void * void_st, const std::string& filename,

names.push_back(name);
int taxId = -1;
for (gemmi::Residue &res : ch.residues) {
for (gemmi::Residue &res : ch.first_conformer()) {
if (taxId == -1) {
auto it = entity_to_tax_id.find(res.entity_id);
if (it != entity_to_tax_id.end()) {
Expand All @@ -285,6 +285,10 @@ void GemmiWrapper::updateStructure(void * void_st, const std::string& filename,
if (isHetAtomInList == false && res.het_flag != 'A')
continue;
if (isHetAtomInList) {
bool notPolymer = res.entity_type != gemmi::EntityType::Polymer;
if (notPolymer == true) {
continue;
}
bool hasCA = false;
for (gemmi::Atom &atom : res.atoms) {
if (atom.name == "CA") {
Expand Down

0 comments on commit 0c32b3b

Please sign in to comment.