orient.pdb | R Documentation |
Center, to the coordinate origin, and orient, by principal axes, the coordinates of a given PDB structure or xyz vector.
orient.pdb(pdb, atom.subset = NULL, verbose = TRUE)
pdb |
a pdb data structure obtained from |
atom.subset |
a subset of atom positions to base orientation on. |
verbose |
print dimension details. |
Returns a numeric vector of re-oriented coordinates.
Centering and orientation can be restricted to a atom.subset
of atoms.
Barry Grant
Grant, B.J. et al. (2006) Bioinformatics 22, 2695–2696.
read.pdb
, write.pdb
,
fit.xyz
, rot.lsq
, atom.select
# PDB server connection required - testing excluded
try({
pdb <- read.pdb( "1bg2" )
xyz <- orient.pdb(pdb)
#write.pdb(pdb, xyz = xyz, file = "mov1.pdb")
# Based on C-alphas
inds <- atom.select(pdb, "calpha")
xyz <- orient.pdb(pdb, atom.subset=inds$atom)
#write.pdb(pdb, xyz = xyz, file = "mov2.pdb")
# Based on a central Beta-strand
inds <- atom.select(pdb, resno=c(224:232), elety='CA')
xyz <- orient.pdb(pdb, atom.subset=inds$atom)
#write.pdb(pdb, xyz = xyz, file = "mov3.pdb")
}, silent=TRUE)
if(inherits(.Last.value, "try-error")) {
message("Need internet to run the example")
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.