BioJava:CookBook3:ModFinder
How can I identify protein modifications in a structure?
BioJava provide a module biojava3-modfinder for identification of protein pre-, co-, and post-translational modifications from structures. A list of protein modifications has been pre-loaded. It is possible to identify all pre-loaded modifications or part of them.
Example: identify and print all preloaded modifications from a structure
Set<ModifiedCompound> identifyAllModfications(Structure struc) {
ProteinModificationIdentifier parser = new ProteinModificationIdentifier();
parser.identify(struc);
Set`<ModifiedCompound> mcs = parser.getIdentifiedModifiedCompound();
return mcs;
}
Example: identify phosphorylation sites in a structure
```java List
List<ResidueNumber> phosphosites = new ArrayList
} ```
Demo code to run the above methods
```java import org.biojava.nbio.structure.ResidueNumber; import org.biojava.nbio.structure.Structure; import org.biojava.nbio.structure.io.PDBFileReader; import org.biojava.nbio.protmod.structure.ProteinModificationIdentifier;
public static void main(String[] args) {
try {`
PDBFileReader reader = new PDBFileReader();
reader.setAutoFetch(true);
// identify all modificaitons from PDB:1CAD and print them
String pdbId = "1CAD";
Structure struc = reader.getStructureById(pdbId);
Set
// identify all phosphosites from PDB:3MVJ and print them
pdbId = "3MVJ";
struc = reader.getStructureById(pdbId);
List
} ```