Learn R Programming

fbar (version 0.6.0)

gene_eval: Function to estimate the expression levels of gene sets

Description

Function to estimate the expression levels of gene sets

Usage

gene_eval(gene_sets, genes, presences)

Arguments

gene_sets

A list of gene set strings: names of genes punctuated with &, | and brackets.

genes

A list of gene names

presences

A list of gene presences, the same length as genes

Value

a vector the same length as gene_sets, with the the calculated combined gene expression levels.

This function evaluates the gene sets in the context of the gene presences. It can take booleans, or numbers, in which case it associates & with finding the minimum, and | with finding the maximum.

Warning

This function uses eval to evaluate gene expression sets. This gives flexibility, but means that malicious code in the gene_sets argument could get evaluated. gene_sets is evaluated in a restricted environment, but there might be a way around this, so you might want to check for anything suspicious in this argument manually. For more information, read the code.

See Also

gene_associate