addIds: addIds

Description Usage Arguments Value Examples

View source: R/addIds.R

Description

Adds entrez or ensembl IDs to the nested dataframes within a list(c) or list of lists (s). The IDs are created by the getIdsMir and getIdsMrna functions, both are needed for addIds.

Usage

1
addIds(MAE, method, filtered_genelist, miR_IDs, mRNA_IDs)

Arguments

MAE

MultiAssayExperiment to store the output of addIds. It is recommended to use the MAE which stores results from significantVals.

method

Either "c" or "s", respectively for combined or separated analysis.

filtered_genelist

A list of nested dataframes if 'c' or a list of lists with nested dataframes if 's'. This will be found as metadata within the MAE object used in the significantVals function.

miR_IDs

miR_ensembl or miR_entrez. Use a getIDsMir function to acquire this. This will be stored as an assay in the MAE used in a getIdsMir function.

mRNA_IDs

mRNA_ensembl or mRNA_entrez. Use a getIDsMrna function to acquire this. This will be stored as an assay in the MAE used in a getIdsMrna function.

Value

List of dataframes with entrezIDs/ ensembl IDs and gene names as columns which will be stored as metadata in the input MAE.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
library(org.Mm.eg.db)

data(mm_miR)

data(mm_mRNA)

Data <- startObject(miR = mm_miR, mRNA = mm_mRNA)

Data <- getIdsMir(Data, assay(Data, 1), orgDB = org.Mm.eg.db, 'mmu')

Data <- getIdsMrna(Data, assay(Data, 2), mirror = 'useast', 'mmusculus')

Data <- combineGenes(MAE = Data, miR_data = assay(Data, 1),
                     mRNA_data = assay(Data, 2))

Data <- genesList(MAE = Data, method = 'c', genetic_data = assay(Data, 9),
                  timeString = 'D')

Data <- significantVals(MAE = Data, method = 'c',
                        geneList = metadata(Data)[[1]],
                        maxVal = 0.05, stringVal = "adjPVal")

Data <- addIds(MAE = Data, method = "c",
              filtered_genelist = metadata(Data)[[2]],
              miR_IDs = assay(Data, 3), mRNA_IDs = assay(Data, 7))

TimiRGeN documentation built on April 17, 2021, 6:03 p.m.