specific.annotation.matrix: Specific annotation matrix

View source: R/annotation.utility.R

specific.annotation.matrixR Documentation

Specific annotation matrix

Description

Build the annotation matrix of the most specific functional terms.

Usage

specific.annotation.matrix(file = "gene2pheno.txt.gz")

Arguments

file

text file representing the associations gene-ontology terms. The file must be written as sequence of rows. Each row represents a gene/protein and all its associations with an ontology term (pipe separated), i.e. in the form e.g.: gene1 |obo1|obo2|...|oboN.

Details

The input plain text file (representing the associations gene-ontology terms) can be obtained by cloning the GitHub repository obogaf-parser, a perl5 module specifically designed to handle HPO and GO obo files and their gene annotation files (gaf file).

Value

The annotation matrix of the most specific annotations (0/1): rows are genes and columns are functional terms (such as GO or HPO). Let's denote M the labels matrix. If M[i,j]=1, means that the gene i is annotated with the class j, otherwise M[i,j]=0.

Examples

gene2pheno <- system.file("extdata/gene2pheno.txt.gz", package="HEMDAG");
spec.ann <- specific.annotation.matrix(file=gene2pheno);

marconotaro/HEMDAG documentation built on Nov. 20, 2024, 6:02 p.m.