|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.io.File ProGAL.proteins.PDBFile
public class PDBFile
A class for reading and representing a PDB-file. All lines are read but not all are parsed. All the records can be retrieved as they are shown in the PDB-file. The ATOM-records, however, can also be accessed according to model and chain id. If a model-number and chain id are not specified the method will assume that the first chain of the first model is meant. In some files there are multiple suggestions for atom-placements. This is resolved by only reading the first suggested atom-placement. The other atom-placements are added to the alternativeCoords LinkedList in the first atom-record. The four-letter PDB id and chain id are guessed based on the filename. TODO: Represent ligands, heterogens and secondary structure. TODO: Check the integrity of different models, e.g. that the sequences are the same.
Nested Class Summary | |
---|---|
static class |
PDBFile.AnisouRecord
|
static class |
PDBFile.AtomRecord
|
static class |
PDBFile.EndModelRecord
|
static class |
PDBFile.HelixRecord
|
static class |
PDBFile.HetatmRecord
|
static class |
PDBFile.ModelRecord
|
static class |
PDBFile.OtherRecord
|
static class |
PDBFile.ParentRecord
|
static class |
PDBFile.PDBChain
|
static class |
PDBFile.PDBModel
|
static interface |
PDBFile.PDBRecord
|
static class |
PDBFile.RemarkRecord
|
static class |
PDBFile.SheetRecord
|
static class |
PDBFile.TerRecord
|
Field Summary | |
---|---|
java.lang.String |
name
The name of this PDB-file. |
Fields inherited from class java.io.File |
---|
pathSeparator, pathSeparatorChar, separator, separatorChar |
Constructor Summary | |
---|---|
PDBFile(java.io.File f)
Construct a PDB-file from the specified file |
|
PDBFile(java.lang.String path)
Construct a PDB-file from the specified file-path |
Method Summary | |
---|---|
static PDBFile |
downloadPDBFile(java.lang.String pdbId)
Read a PDB-file from www.pdb.org. |
PDBFile.AtomRecord |
getAtom(int res,
java.lang.String atomType)
|
java.util.List<Point> |
getAtomCoords()
Returns all atom-coordinates in the first chain in the first model. |
java.util.List<Point> |
getAtomCoords(int modelNum,
int chainNum)
Returns all atom-coordinates of the specified model and chain. |
java.util.List<Point> |
getAtomCoords(java.lang.String atomTypes)
Returns the coordinates of the specified atom types. |
java.util.List<PDBFile.AtomRecord> |
getAtomRecords()
Returns the ATOM-records. |
java.util.List<PDBFile.AtomRecord> |
getAtomRecords(int modelNum,
int chainNum)
Returns the ATOM-records of the specified model and chain. |
java.util.List<PDBFile.AtomRecord> |
getAtomRecords(java.lang.String atomTypes)
Returns the ATOM-records. |
java.util.List<Point> |
getCACoords()
Returns the CA-coordinates of atoms in the first chain in the first model. |
java.util.List<Point> |
getCACoords(int modelNum,
int chainNum)
Returns the CA-coordinates of the specified model and chain. |
java.util.List<PDBFile.AtomRecord> |
getCARecords()
Returns the ATOM-records of CA-atoms. |
java.util.List<PDBFile.AtomRecord> |
getCARecords(int modelNum,
int chainNum)
Returns the CA ATOM-records of the specified model and chain. |
AminoAcidChain |
getChain(int modelNum,
int chainNum)
|
java.util.List<PDBFile.HetatmRecord> |
getHetatmRecords()
|
java.util.List<PDBFile.HetatmRecord> |
getHetatmRecords(int modelNum,
int chainNum)
Returns the HETATM-records of the specified model and chain. |
java.util.List<PDBFile.PDBModel> |
getModels()
|
java.util.List<PDBFile.PDBRecord> |
getRecords()
Returns all records of the specified model and chain. |
java.util.List<PDBFile.RemarkRecord> |
getRemarkRecords()
Returns all REMARK records. |
double |
getResolution()
|
java.lang.String |
getSequence()
|
static void |
main(java.lang.String[] args)
|
void |
setIncludeHetatms(boolean b)
|
void |
setIncludeHydrogens(boolean b)
|
void |
setStandardChain(char c)
|
void |
setStandardChain(int c)
|
void |
setStandardModel(int m)
|
double |
superposeOnto(PDBFile f)
|
Methods inherited from class java.io.File |
---|
canExecute, canRead, canWrite, compareTo, createNewFile, createTempFile, createTempFile, delete, deleteOnExit, equals, exists, getAbsoluteFile, getAbsolutePath, getCanonicalFile, getCanonicalPath, getFreeSpace, getName, getParent, getParentFile, getPath, getTotalSpace, getUsableSpace, hashCode, isAbsolute, isDirectory, isFile, isHidden, lastModified, length, list, list, listFiles, listFiles, listFiles, listRoots, mkdir, mkdirs, renameTo, setExecutable, setExecutable, setLastModified, setReadable, setReadable, setReadOnly, setWritable, setWritable, toString, toURI, toURL |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public java.lang.String name
Constructor Detail |
---|
public PDBFile(java.lang.String path)
public PDBFile(java.io.File f)
Method Detail |
---|
public static PDBFile downloadPDBFile(java.lang.String pdbId)
public void setStandardModel(int m)
public void setStandardChain(int c)
public void setIncludeHydrogens(boolean b)
public void setIncludeHetatms(boolean b)
public void setStandardChain(char c)
public java.util.List<PDBFile.PDBModel> getModels()
public java.util.List<PDBFile.AtomRecord> getAtomRecords()
public java.util.List<PDBFile.AtomRecord> getAtomRecords(java.lang.String atomTypes)
atomTypes
- A comma separated list of atom types. Could, for example, be "CA,C,N,O" to specify
backbone atoms only.public java.util.List<PDBFile.AtomRecord> getCARecords()
public java.util.List<Point> getCACoords()
public java.util.List<Point> getAtomCoords()
public java.util.List<Point> getAtomCoords(java.lang.String atomTypes)
atomTypes
- A comma separated list of atom types. Could, for example, be "CA,C,N,O" to specify
backbone atoms only.public java.util.List<PDBFile.AtomRecord> getAtomRecords(int modelNum, int chainNum)
public java.util.List<PDBFile.HetatmRecord> getHetatmRecords()
public java.util.List<PDBFile.HetatmRecord> getHetatmRecords(int modelNum, int chainNum)
public java.util.List<PDBFile.PDBRecord> getRecords()
public java.util.List<PDBFile.AtomRecord> getCARecords(int modelNum, int chainNum)
public java.util.List<Point> getCACoords(int modelNum, int chainNum)
public java.util.List<Point> getAtomCoords(int modelNum, int chainNum)
public AminoAcidChain getChain(int modelNum, int chainNum)
public java.util.List<PDBFile.RemarkRecord> getRemarkRecords()
public PDBFile.AtomRecord getAtom(int res, java.lang.String atomType)
public java.lang.String getSequence()
public double getResolution()
public double superposeOnto(PDBFile f)
public static void main(java.lang.String[] args)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |