make_gene_expression_compendium: make_gene_expression_compendium

Description Usage Arguments Details Value Examples

View source: R/c3_functions.R

Description

This function makes a compendium (matrix) of gene expression data by transforming a list or matrix of gene expression profiles (with replicates) representing different cell types or tissues.

Usage

1
2
make_gene_expression_compendium(gene.expression.data, species = "hsapiens",
  experiment.descriptor = NULL, expression.data.format = "list")

Arguments

gene.expression.data

A list or matrix containing gene expression profiles. For list each element will be treated as an individual cell/tissue, therefore it should have a unique name and contain a vector of gene expression values, or a matrix with replicates. For a matrix input, the row names denote the genes and column names denote the cell type or tissue. Duplicate column names are expected in this case denoting replicate samples. All the replicate samples for a specific cell or tissue should have identical column names, otherwise the experiment.descriptor parameter should be used to identify replicate samples of a specific cell type or tissue.

species

The species abbreviation of the compendium data (gene.expression.data). Default is "hsapiens".

experiment.descriptor

A vector corresponding to the column names (matrix) or elements (list) of gene.expression.data, containing the cell type or tissues of each sample. The names should be identical for a specific cell or tissue. Defaults to NULL.

expression.data.format

The format of gene.expression.data, either 'list' or 'matrix'. Defaults to "list".

Details

This function makes a compendium (matrix) of gene expression data by transforming a list or matrix of gene expression profiles (with replicates) representing different cell types or tissues. For both the input and output matrices, rows denote genes and columns denote cell/tissue types. The compendium can be generated with any type of valid gene IDs, and can then be converted to ensembl_gene_id using function convert_geneID_to_ensemblID with appropriate parameters.

Value

This function returns a list with two elements. The element 'counts' is the compendium matrix where rows denote genes and columns denote individual cell types or tissues. The element 'species' represents the compendium data species.

Examples

1
2
3
4
exp.data<-matrix(sample(1:10, 100, replace=TRUE),10,10)
rownames(exp.data)<-c("ENSG00000100053", "ENSG00000109846", "ENSG00000244752", "ENSG00000138083", "ENSG00000181449", "ENSG00000160202", "ENSG00000007372", "ENSG00000117707", "ENSG00000101144", "ENSG00000277354")
colnames(exp.data)<-c("cell1", "cell1", "cell1", "cell2", "cell2", "cell2", "cell3", "cell3", "cell3", "cell3")
make_gene_expression_compendium(gene.expression.data=exp.data, expression.data.format="matrix")

VCCRI/C3 documentation built on May 14, 2019, 8:41 a.m.