Skip to content

Commit

Permalink
query stage for structure components when making PDB
Browse files Browse the repository at this point in the history
  • Loading branch information
gamcil committed Sep 2, 2024
1 parent e405e44 commit c02dfad
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions frontend/StructureViewerMSA.vue
Original file line number Diff line number Diff line change
Expand Up @@ -128,22 +128,24 @@ export default {
let result = `\
TITLE Superposed structures from Foldmason alignment
REMARK This file was generated by the FoldMason webserver:
REMARK https://mason.foldseek.com
REMARK https://search.foldseek.com/foldmason
REMARK Please cite:
REMARK <insert citation>
REMARK https://doi.org/10.1101/2024.08.01.606130
REMARK Warning: Non C-alpha atoms may have been re-generated by PULCHRA
REMARK if they are not present in the original PDB file.
`;
this.structures.forEach((structure, index) => {
PDB = new PdbWriter(structure.structure.structure, { renumberSerial: false }).getData();
this.stage.eachComponent(comp => {
PDB = new PdbWriter(comp.structure, { renumberSerial: false }).getData();
PDB = PDB.split('\n').filter(line => line.startsWith("ATOM")).join('\n');
let index = parseInt(comp.structure.name.replace("key-", ""));
let name = this.entries[index].name;
result += `\
MODEL ${index}
REMARK Name: ${structure.name}
REMARK Name: ${name}
${PDB}
ENDMDL
`;
});
}, "structure")
result += "END";
download(new Blob([result], { type: 'text/plain' }), "foldmason.pdb")
},
Expand Down

0 comments on commit c02dfad

Please sign in to comment.