apset2descdb {ChemmineR} | R Documentation

## `APset` to list-style AP database

### Description

Coerces APset to old list-style descriptor database used by search/cluster functions.

### Usage

    apset2descdb(apset)

### Arguments

`apset` | Object of class `apset`

### Details

...

### Value

`list` | with following components
`descdb` | list of atom pair sets
`cids` | compound IDs
`sdfsegs` | start/end coordinates for each molecule in SD file; only populated when `cmp.parse` is used for import
`source` | path/name of SD file
`type` | import method

### Author(s)

Thomas Girke

### References

Chen X and Reynolds CH (2002). "Performance of similarity measures in 2D fragment-based similarity searching: comparison of structural descriptors and similarity coefficients", J Chem Inf Comput Sci.

### See Also

Functions: `SDF2apcmp`, `sdf2ap`, `cmp.search`, `cmp.similarity`

### Examples

    ## Instance of SDFset class
    data(sdfsample)
    sdfset <- sdfsample[1:50]
    sdf <- sdfsample[[1]]

    ## Compute atom pair library
    ap <- sdf2ap(sdf)
    (apset <- sdf2ap(sdfset))
    view(apset[1:4])

    ## Return main components of APset object
    cid(apset[1:4]) # compound IDs
    ap(apset[1:4]) # atom pair descriptors

    ## Return atom pairs in human readable format
    db.explain(apset[1])

    ## Coerce APset to other objects
    apset2descdb(apset) # returns old list-style AP database
    tmp <- as(apset, "list") # returns list
    as(tmp, "APset") # converst list back to APset

    ## Compound similarity searching with APset
    cmp.search(apset, apset[1], type=3, cutoff=0.2)
    plot(sdfset[names(cmp.search(apset, apset[6], type=2, cutoff=0.4))])

    ## Identify compounds with identical AP sets
    cmp.duplicated(apset, type=2)

    ## Structure similarity clustering
    cmp.cluster(db=apset, cutoff = c(0.65, 0.5))[1:20,]

[Package ChemmineR version 3.46.0 Index]