rnb.sample.groups {RnBeads} | R Documentation

## rnb.sample.groups

### Description

Identifies sample subgroups defined in the given annotation information.

### Usage

    rnb.sample.groups(annotations, columns = NULL, columns.pairs = NULL,
      min.group.size = rnb.getOption("min.group.size"),
      max.group.count = rnb.getOption("max.group.count"))

### Arguments

`annotations` | Methylation dataset as an object of type inheriting `RnBSet`, or its sample annotations in the form of a `data.frame`. If this parameter is a dataset, the annotation information is extracted using the method `pheno`.
`columns` | Optional; predefined column names (in the form of a `character` vector) or indices (an `integer` vector) to consider. All other columns in the annotation table will be ignored.
`columns.pairs` | Optional; a NAMED vector containing for each column name for which paired comparisons should be performed (say columnA) the name or index of another column (say columnB) in which same values indicate the same pairing. columnA should be the name of the value columnB in this vector.
`min.group.size` | Minimum number of samples in each subgroup. This must be a positive `integer`.
`max.group.count` | Maxumum number of subgroups defined by a trait. This must be an `integer` greater than 1.

### Value

List of traits that define subgroups in the dataset. For each trait, the defined subgroups are represented by a list of `integer` vectors storing the corresponding sample indices.

### Author(s)

Yassen Assenov

### Examples

    library(RnBeads.hg19)
    data(small.example.object)
    str(rnb.sample.groups(rnb.set.example))

[Package RnBeads version 1.12.1 Index]