write.pdb {Rpdb} | R Documentation |
PDB File Writer
Description
Writes a Protein Data Bank (PDB) coordinate file from an object of class ‘pdb’.
Usage
write.pdb(x, file = "Rpdb.pdb")
Arguments
x |
an object, or a list of objects, of class ‘pdb’. |
file |
a single element character vector containing the name of the PDB file to be created. |
Details
All data stored in the ‘pdb’ object are written to a PDB file. A list of objects of class ‘pdb’ can be provided to write multiple MODEL data into a single file. In this case, each ‘pdb’ object of the list must have the same cryst1
and conect
components.
To write only a subset of a ‘pdb’ object see function subset.pdb
.
Value
No return value, called for side effects.
References
PDB format is described at: http://www.wwpdb.org/documentation/format33/v3.3.html
See Also
read.pdb
, pdb
, cryst1
, atoms
, conect
, subset.pdb
Examples
# Read a PDB file included with the package
pdb <- read.pdb(system.file("examples/PCBM_ODCB.pdb", package="Rpdb"))
# Write the pdb object to file "Rpdb.pdb" in the current directory
write.pdb(pdb, file = "Rpdb.pdb")
# Cleanup
unlink("Rpdb.pdb")
[Package Rpdb version 2.3.4 Index]