PDB parser

I was working on a parser to read protein structure data files as part of my project on studying protein folding classification. However, after putting that research project aside, the work on the parser also ceased. Thus, only a partial implementation is available.

The idea of the approach was not primarily to read the data into a fixed data structure; but rather to give methods which are by default empty, but which may be implemented to produce any desired data structure. Of course, such was also to be made, in particular, one to produce a molecular structure with data on multiple chains, secondary structure, bondings, and heterogeneous elements; though that never happened.

Java download

The main package is the PDB parser package (no.uio.labmed.pdb.*). This contains two classes, Test and TestParser, which are runable (implements main) taking a PDB file name as argument. These two test classes use a helper package to present results (no.uio.labmed.output.*).

Understanding how to make use of the implementation is perhaps best done by looking at the Test and TestParser classes: these two are almost identical. TestParser implements the PDBparser class; Test implements PDBinterpreter which in turn implements PDBparser.

The PDBparser class simply parses the PDB file, calling methods for parsed element (secondary structure element, atom, etc.); extentions of PDBparser overriding the default methods may then be used to actually process the data.

The PDBinterpreter class was aimed at helping interpreting the data from the PDBparser somewhat better, i.e. help organize atoms into residues etc., but this was never completed.

The packages were made quite some time ago under an older version of Java, but I have gone over the code just to make it compliant with Java 5. I'm afraid method and variable names may be interchangably in English and in Norwegian: at least in the output package.

The pdb package contains the pdb parser classes. The output package is just a small utility package I made many years ago to help produce a tabbed window to put information into and not ment to be part of the parser package, but it was useful to have during development.

If anyone are able to make something useful based on this package, or instead of this package for that matter, and are prepared to make it available for others to download, please drop me a hint so I can link to it: then others coming here to search for a Java PDB parser package can be directed to something more complete than what I have to offer here.

Last modified February 10, 2008.