Description Usage Arguments Value Examples
View source: R/uniqGenesetsByNamespace.R
Make names of gene-sets unique by namespace, and member genes of gene-sets unique
1 | uniqGenesetsByNamespace(gmtList)
|
gmtList |
A The function make sure that
Gene-sets with duplicated names and different |
A GmtList
object, with unique gene-sets and unique gene lists. If not already present, a new item namespace
is appended to each list
element in the GmtList
object, recording the namespace used to make gene-sets unique. The order of the returned GmtList
object is given by the unique gene-set name of the input object.
1 2 3 4 5 6 7 8 9 | myGmtList <- GmtList(list(list(name="GeneSet1", desc="Namespace1", genes=LETTERS[1:3]),
list(name="GeneSet2", desc="Namespace1", genes=rep(LETTERS[4:6],2)),
list(name="GeneSet1", desc="Namespace1", genes=LETTERS[4:6]),
list(name="GeneSet3", desc="Namespace2", genes=LETTERS[1:5])))
print(myGmtList)
myGmtList <- setNamespace(myGmtList, namespace=function(x) x$desc)
myUniqGmtList <- uniqGenesetsByNamespace(myGmtList)
print(myUniqGmtList)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.