Reduce a SummarizedExperiment object so that it only now contains a subset of genes.

convertSESubsetGenes(dataSE, geneList)

Arguments

dataSE

SUMMARIZEDEXPERIMENT | Summarized experiment format that can be used in lieu of data and dataMetrics

geneList

CHARACTER ARRAY | List of gene IDs to remain in dataSE

Value

A new dataSE object that is a subset of the input dataSE in that it now only contains the user-specified list of genes.

Examples

# Example: Read in example SummarizedExperiment object that originally # contains 5604 genes. Reduce it to now only contain ten genes (specifically # the ones with the lowest FDR). suppressMessages(library(dplyr)) suppressMessages(library(SummarizedExperiment))
#> Warning: package ‘S4Vectors’ was built under R version 3.6.3
#> Warning: package ‘GenomeInfoDb’ was built under R version 3.6.3
#> Warning: package ‘DelayedArray’ was built under R version 3.6.3
data(se_soybean_ir_sub) geneList <- as.data.frame(rowData(se_soybean_ir_sub)) %>% arrange(N_P.FDR) %>% filter(row_number() <= 10) geneList <- geneList[,1] se_soybean_ir_sub_2 <- convertSESubsetGenes(se_soybean_ir_sub, geneList)