use of de.bioforscher.jstructure.feature.sse.dssp.DSSPSecondaryStructure in project jstructure by JonStargaryen.
the class DictionaryOfProteinSecondaryStructureTest method getSecondaryStructureAnnotation.
private String getSecondaryStructureAnnotation(String id) {
// load structure
Structure protein = StructureParser.fromPdbId(id).parse();
// assign states
featureProvider.process(protein);
// return complete DSSP annotation string from jstructrue
return protein.aminoAcids().map(residue -> residue.getFeature(DSSPSecondaryStructure.class)).map(DSSPSecondaryStructure::getSecondaryStructure).map(SecondaryStructureType::getOneLetterRepresentation).map(character -> character.equals("c") ? " " : character).collect(Collectors.joining());
}
use of de.bioforscher.jstructure.feature.sse.dssp.DSSPSecondaryStructure in project jstructure by JonStargaryen.
the class DictionaryOfProteinSecondaryStructureTest method test1bta.
@Test
public void test1bta() {
Structure structure = StructureParser.fromPdbId("1bta").parse();
featureProvider.process(structure);
structure.aminoAcids().forEach(aminoAcid -> {
System.out.println(aminoAcid);
DSSPSecondaryStructure sse = aminoAcid.getFeature(DSSPSecondaryStructure.class);
System.out.println(sse.getSecondaryStructure().name());
});
System.out.println(structure.getFirstChain().aminoAcids().map(aminoAcid -> aminoAcid.getFeature(DSSPSecondaryStructure.class).getSecondaryStructure().getOneLetterRepresentation()).collect(Collectors.joining()));
}
Aggregations