PageRenderTime 25ms CodeModel.GetById 22ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/rcdk/man/atomcontainer.Rd

http://github.com/rajarshi/cdkr
Unknown | 70 lines | 59 code | 11 blank | 0 comment | 0 complexity | 413484ece5549cf5f2d800555689d920 MD5 | raw file
 1\name{Molecule}
 2\alias{get.exact.mass}
 3\alias{get.natural.mass}
 4\alias{is.neutral}
 5\alias{convert.implicit.to.explicit}
 6\title{
 7	Operations on molecules
 8}
 9\description{
10	Various functions to perform operations on molecules. 
11
12	\code{get.exact.mass} returns the exact mass of a molecule
13
14	\code{get.natural.mass} returns the natural exact mass of a molecule	
15
16	\code{convert.implicit.explicit} converts implicit hydrogens
17	to explicit hydrogens. This function does not return any value
18	but rather modifies the molecule object passed to it
19
20	\code{is.neutral} returns \code{TRUE} if all atoms in the molecule
21	have a formal charge of 0, otherwise \code{FALSE}
22}
23\usage{
24get.exact.mass(molecule)
25get.natural.mass(molecule)
26convert.implicit.to.explicit(molecule)
27is.neutral(molecule)
28}
29\arguments{
30  \item{molecule}{A \code{jObjRef} representing an IAtomContainer or IMolecule object}
31}
32\value{
33	\code{exact.mass} returns a numeric
34
35	\code{get.natural.mass} returns a numeric
36
37	\code{convert.implicit.to.explicit} has no return value
38
39	\code{is.neutral} returns a boolean.
40}
41\details{
42In some cases, a molecule may not have any hydrogens (such as when read
43in from an MDL MOL file that did not have hydrogens). In such cases, 
44\code{\link{convert.implicit.to.explicit}} 
45will add implicit hydrogens and then convert them to explicit ones. In addition, for
46such cases, make sure that the molecule has been typed beforehand.
47}
48\keyword{programming}
49\seealso{
50  \code{\link{get.atoms}}, \code{\link{do.typing}}
51}
52\examples{
53  m <- parse.smiles('c1ccccc1')[[1]]
54
55  ## Need to configure the molecule
56  do.aromaticity(m)
57  do.typing(m)
58  do.isotopes(m)
59
60  get.exact.mass(m)
61  get.natural.mass(m)
62
63  convert.implicit.to.explicit(m)
64  get.natural.mass(m) 
65  do.isotopes(m) # Configure isotopes of newly added hydrogens
66  get.exact.mass(m)
67
68  is.neutral(m)
69}
70\author{Rajarshi Guha (\email{rajarshi.guha@gmail.com})}