collapse {Onassis} | R Documentation

## `collapse`

### Description

This method collapses semantic states in an Onassis object.

### Usage

    collapse(onassis = NA, simil_thresh)

    ## S4 method for signature 'Onassis'
    collapse(onassis = NA, simil_thresh)

### Arguments

`onassis` | instance of class `Onassis-class`
`simil_thresh` | the semantic similarity threshold to use to merge similar semantic sets

### Value

a new object of class `Onassis-class` with collapsed annotations for the entities and a new similarity matrix of similarities between newly created semantic sets

### Examples

    geo_chip <- readRDS(system.file('extdata', 'vignette_data',
    'GEO_human_chip.rds', package='Onassis'))
    obo <- system.file('extdata', 'sample.cs.obo', package='OnassisJavaLibs')
    onassis_results <- annotate(geo_chip, 'OBO', dictionary=obo)
    entities <- entities(onassis_results)
    entities(onassis_results) <- entities[sample(nrow(entities), 15),]
    onassis_results <- sim(onassis_results)
    collapsed_onassis <- collapse(onassis_results, 0.9)

[Package Onassis version 1.2.7 Index]