extractPDB: Extract Data from a PDB-File

Description Usage Arguments Details Value Note Author(s) References Examples

View source: R/extractPDB.r

Description

This function reads a PDB file and extracts data from it.

Usage

1
extractPDB(file.name, verbose = TRUE)

Arguments

file.name

name of the PDB file

verbose

logical, if TRUE prints the output from both functions read.pdb() and atom.select().

Details

The input PDB file is read. All C_{α} atoms are extracted. For each C_{α} atom the x-, y- and z-coordinates as well as the amino acid type and the B factor are extracted. The sequence length is compared to the number of C_{α} atoms in the PDB. For each chain of the protein the length is computed.

Value

Returns a list with the following components:

pdb

list of class “pdb” as originally extracted by read.pdb() in the bio3d package

seq

sequence according to the “SEQRES” entries of the PDB file

lseq

length of the extracted sequence seq

lca

number of C_{α} atoms

caseq

sequence data for the C_{α} selection

coords

matrix of coordinates for each C_{α} atom, the rows are the C_{α}'s, the columns are x, y, z

b

B factor for each C_{α}

chains

integer vector with the lengths of the different chains in the protein sequence

Note

Alternate and insert records in the PDB file are ignored. When removing alternate records a message is printed. Please check the PDB file.

If the number of C_{α} atoms lca and the length of the extracted sequence seq differ, a message is printed. It is not advisable to use any other parts of the BioPhysConnectoR-package until you have found an appropriate solution to deal with this problem in the pdb-file.

This function includes source code of the bio3d package.

Author(s)

Franziska Hoffgaard

References

Grant, Rodrigues, ElSawy, McCammon, Caves, (2006) Bioinformatics 22, 2695–2696.

Examples

1
pdb<-extractPDB(system.file("1KZK.pdb", package = "BioPhysConnectoR"))

Example output

Loading required package: snow
Loading required package: matrixcalc
  HEADER    VIRAL PROTEIN, HYDROLASE                06-FEB-02   1KZK               
   PDB has ALT records, taking A only, rm.alt=TRUE
      segid  chain  resno  resid  eleno  elety
Stest ""     ""     ""     ""     ""     "CA" 
Natom "3019" "3019" "3019" "3019" "3019" "198"
 *  Selected a total of: 198 intersecting atoms  *

BioPhysConnectoR documentation built on May 30, 2017, 6:46 a.m.