| atoms | R Documentation |
Creates an object of class ‘atoms’ containing the data related to ATOM and HETATM records of a PDB file.
atoms(...)
## Default S3 method:
atoms(
recname,
eleid,
elename,
alt,
resname,
chainid,
resid,
insert,
x1,
x2,
x3,
occ,
temp,
segid,
basis = "xyz",
...
)
is.atoms(x)
... |
arguments passed to methods. |
recname |
a character vector containing the record name for each element. |
eleid |
a integer vector containing the element ID for each element. |
elename |
a character vector containing the element name for each element. |
alt |
a character vector containing the alternate location indicator for each element. |
resname |
a character vector containing the residue name for each element. |
chainid |
a character vector containing the chain ID for each element. |
resid |
a integer vector containing the residue ID for each element. |
insert |
a character vector containing the codes for insertion of residue of each element. |
x1, x2, x3 |
a numeric vector containing the first, second and third coordinate for each element. |
occ |
a numeric vector containing the occupancie for each element. |
temp |
a numeric vector containing the temperature factor for each element. |
segid |
a character vector containing the segment ID for each element. |
basis |
a single element character vector indicating the type of basis vector used to express the atomic coordinates. |
x |
an R obecjt to be tested. |
atoms is a generic function to create objects of class ‘atoms’.
The purpose of this class is to store ATOM and HETATM records from PDB files.
The default method creates a atoms object from its different
components, i.e.: recname, eleid, elename, alt,
resname, chainid, resid, insert, x1,
x2, x3, occ, temp, segid and basis.
All the arguments have to be specified except basis which by default
is set to "xyz" (Cartesian coordinates).
is.atoms tests if an object
of class ‘atoms’, i.e. if it has a “class” attribute equal to
atoms.
atoms returns a data.frame of class ‘atoms’ with the following components:
a character vector containing the record name for each element.
a integer vector containing the element ID for each element.
a character vector containing the element name for each element.
a character vector containing the alternate location indicator for each element.
a character vector containing the residue name for each element.
a character vector containing the chain ID for each element.
a integer vector containing the residue ID for each element.
a character vector containing the codes for insertion of residue for each element.
a numeric vector containing the first, second and third coordinate for each element.
a numeric vector containing the occupencie for each element.
a numeric vector containing the temperature factor for each element.
a character vector containing the segment ID for each element.
a single element character vector indicating the type of basis vector used to express the atomic coordinates.
is.atoms returns TRUE if x is an object of class ‘atoms’ and FALSE otherwise.
basis, coords, pdb
x <- atoms(recname = c("ATOM","ATOM"), eleid = 1:2, elename = c("H","H"), alt = "",
resname = c("H2","H2"), chainid = "", resid = c(1,1), insert = "",
x1 = c(0,0), x2 = c(0,0), x3 = c(0,1), occ = c(0.0,0.0), temp = c(1.0,1.0),
segid = c("H2","H2"))
print(x)
is.atoms(x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.