R/AllGenerics.R
, R/GeneSetDb-methods.R
subsetByFeatures.Rd
Subset a GeneSetDb to only include geneSets with specified features.
GeneSetDb
Character vector of featureIds
are you feature id's entered as themselves (feature_id
), which
is the default, or are you querying by their index into a target expression
object? This is only relevant if you are working with a conform
-ed
GeneSetDb, and further you as a user won't likely invoke this argument,
but is used internally.
pass through arguments
A subset of x
which contains only the geneSets that contain
features found in featureIds
subsetByFeatures(GeneSetDb)
: subset GeneSetDb by feature id's
gdb <- exampleGeneSetDb()
features <- c("55839", "8522", "29087")
(gdb.sub <- subsetByFeatures(gdb, features))
#> ===============================================================================
#> GeneSetDb with 5 defined genesets across 3 collections (0 gene sets are active)
#> Conformed: no
#> -------------------------------------------------------------------------------
#> Key: <collection, name>
#> collection name active N n
#> <char> <char> <lgcl> <int> <int>
#> 1: c2 MOREAUX_MULTIPLE_MYELOMA_BY_TACI_DN FALSE 172 NA
#> 2: c2 SOTIRIOU_BREAST_CANCER_GRADE_1_VS_3_UP FALSE 151 NA
#> 3: c6 MEL18_DN.V1_DN FALSE 148 NA
#> 4: c7 GSE14000_UNSTIM_VS_16H_LPS_DC_UP FALSE 200 NA
#> 5: c7 GSE14308_TH2_VS_TH1_UP FALSE 199 NA
#> -------------------------------------------------------------------------------
#> GeneSetDb with 5 defined genesets across 3 collections (0 gene sets are active)
#> Conformed: no
#> ===============================================================================