Learn R Programming

SOMMD (version 0.1.2)

trj2pdb: Extract frame to pdb

Description

Extract a trj frame to a pdb object

Usage

trj2pdb(trj, frame, filename)

Value

a pdb object of the selected frame

Called for its effect.

Arguments

trj

a trj object.

frame

the frame to extract.

filename

for the output pdb file

Author

Stefano Motta stefano.motta@unimib.it

Examples

Run this code
# \donttest{
# Read the trajectory
trj <- read.trj(trjfile = system.file("extdata", "HIF2a-MD.xtc", package = "SOMMD"),
  topfile = system.file("extdata", "HIF2a.gro", package = "SOMMD"))
# Write the pdb file for a specific frame
trj2pdb(trj = trj, frame=5, filename = tempfile(fileext = '.pdb' ))
# }

Run the code above in your browser using DataLab