Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

cryst1

Create ‘cryst1’ Object


Description

Create an object of class ‘cryst1’ containing the unit cell parameters and the name of the space group to associate with an object of class ‘pdb’.

Usage

cryst1(...)

## Default S3 method:
cryst1(abc, abg = c(90, 90, 90), sgroup = "P1", ...)

is.cryst1(x)

Arguments

abc

a numeric vector of length 3 containing the norms of the lattice vectors a, b and c.

abg

a numeric vector of length 3 containing the angles between the lattice vectors α, β and γ.

sgroup

a character string giving the Hermann-Mauguin symbol of the space group.

x

an R obecjt to be tested.

...

further arguments passed to or from other methods.

Details

cryst1 is a generic function to create objects of class ‘cryst1’. The purpose of this class is to store CRYST1 records from PDB files which contain the unit cell parameters and the name of the space group of a molecular system stored in a PDB file. The default method of the cryst1 function create an object of class ‘cryst1’ from its different components, i.e.: abc, abg and sgroup. At least abc has to be specified.

is.cryst1 tests if an object of class ‘cryst1’, i.e. if it has a “class” attribute equal to cryst1.

Value

cryst1 returns a list of class ‘cryst1’ with the following components:

abc

a numeric vector of length 3 containing the norms of the lattice vectors a, b and c.

abg

a numeric vector of length 3 containing the angles between the lattice vectors α, β and γ.

sgroup

a character string giving the Hermann-Mauguin symbol of the space group.



is.Cryst1 returns TRUE if x is an object of class ‘cryst1’ and FALSE otherwise.

See Also

Examples

x <- cryst1(abc = c(10, 10, 10), abg = c(90,90,90), sgroup = "P1")
is.cryst1(x)

Rpdb

Read, Write, Visualize and Manipulate PDB Files

v2.3
GPL
Authors
Julien Idé
Initial release
2014-02-25

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.