get.smiles: Generate a SMILES representation of a molecule.

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/smiles.R

Description

The function will generate a SMILES representation of an 'IAtomContainer' object. The default parameters of the CDK SMILES generator are used. This can mean that for large ring systems the method may fail. See CDK Javadocs for more information

Usage

1
get.smiles(molecule, flavor = smiles.flavors(c("Generic")), smigen = NULL)

Arguments

molecule

The molecule to query. Should be a 'jobjRef' representing an 'IAtomContainer'

flavor

The type of SMILES to generate. See smiles.flavors. Default is 'Generic' SMILES

smigen

A pre-existing SMILES generator object. By default, a new one is created from the specified flavor

Value

A character string containing the generated SMILES

Author(s)

Rajarshi Guha (rajarshi.guha@gmail.com)

References

SmilesGenerator

See Also

parse.smiles, smiles.flavors

Examples

1
2
3
m <- parse.smiles('C1C=CCC1N(C)c1ccccc1')[[1]]
get.smiles(m)
get.smiles(m, smiles.flavors(c('Generic','UseAromaticSymbols')))

Example output

Loading required package: rcdklibs
Loading required package: rJava
[1] "C1C=CCC1N(C)C2=CC=CC=C2"
[1] "C1C=CCC1N(C)c2ccccc2"

rcdk documentation built on March 13, 2020, 1:30 a.m.