cb_test: Chromosome Band Tree-Based Hypothesis Testing

View source: R/cb_test.R

cb_testR Documentation

Chromosome Band Tree-Based Hypothesis Testing

Description

cb_test is a flexible tool for discovering interesting chromosome bands relative to a selected gene list. The function supports local and global tests which can be carried out in a top down or bottom up fashion on the tree of chromosome bands.

Usage

cb_test(selids, chrtree, level, dir = c("up", "down"),
       type = c("local", "global"), next.pval = 0.05,
       cond.pval = 0.05, conditional = FALSE)

Arguments

selids

A vector of gene IDs. The IDs should match those used to annotatate the ChrBandTree given by chrtree. In most cases, these will be Entrez Gene IDs.

chrtree

A ChrBandTree object representing the chromosome bands and the mapping to gene identifiers. The genes in the ChrBandTree are limited to the universe of gene IDs specified at object creation time.

level

An integer giving the level of the chromosome band tree at which testing should begin. The level is conceptualized as the set of nodes with a given path length to the root (organism) node of the chromosome band tree. So level 1 is the chromosome and level 2 is the chromosome arms. You can get a better sense by calling exampleLevels(chrtree)

dir

A string giving the direction in which the chromosome band tree will be traversed when carrying out the tests. A bottom up traversal, from leaves to root, is specified by "up". A top down, from root to leaves, traversal is specified by "down".

type

A string giving the type of test to perform. The current choices are "local" and "global". A local test carries out a chisq.test on each 2 x K contingency table induced by each set of siblings at a given level in the tree. A global test uses the Hypergeometric distribution to compute a p-value for the 2 x 2 tables induced by each band treated independently.

next.pval

The p-value cutoff used to determine whether the parents or children of a node should be tested. After testing a given level of the tree, the decision of whether or not to continue testing the children (or parents) of the already tested nodes is made by comparing the p-value result for a given node with this cutoff; relatives of nodes with values strictly greater than the cutoff are skipped.

cond.pval

The p-value cutoff used to determine whether a node is significant during a conditional test. See conditional.

conditional

A logical value. Can only be used when dir="up" and type="global". In this case, a TRUE value causes a conditional Hypergeometric calculation to be performed. The genes annotated at significant children of a given band are removed before testing.

Value

A list with an element for each level of the tree that was tested. Note that the first element will correspond to the level given by level and that subsequent elements will be the next or previous depending on dir.

Each level element is itself a list consisting of a result list for each node or set of nodes tested. These inner-most lists will have, at least, the following components:

nodes

A character vector of the nodes involved in the test.

p.value

The p-value for the test

observed

The contingency table

method

A brief description of the test method

Author(s)

Seth Falcon


Bioconductor/Category documentation built on Nov. 2, 2024, 6:33 a.m.