Last data update: 2014.03.03

R: compute p-values
computePValuesR Documentation

compute p-values

Description

Compute p-values for genetic interactions terms. Assess if genetic interaction term is different from zero.

Usage

computePValues(sgi,
               method = "pooled.ttest",
               mixTemplateQuery = TRUE,
               p.adjust.function = function(x) { p.adjust(x, method = "BH")},
               verbose = 0)

Arguments

sgi

An object of class RNAinteract.

method

The method used to compute p-values. One of "pooled.ttest","ttest", "limma", "HotellingT2".

For "ttest" a Student t-test is applied for each gene pair. The variance is estimated locally for each gene pair. For "pooled.ttest", a pooled variance is estimated from all gene pairs. The variance applied for each gene pair is the maximum of the pooled and the local variance estimate. This method obtains conservative p-values. For "limma" mediates between the local and the global variance estimation in a Bayesian framework. The limma-package is applied to compute the p-values. For "HotellingT2" Hotelling-T^2 statistics is computed jointly for all dimensions. It results in a single p-value summarizing all channels. For simplification the p-values are stored in a matrix of dimension genes x genes x screens x channels and the p-values are repeated for each channel. The same holds for q-values.

mixTemplateQuery

If a gene-pair is measured twice as template-query and as query-template, a single p-value is computed by combining all measurements, if mixTemplateQuery = TRUE. Else a p-value is computed independently for both cases.

p.adjust.function

A function that corrects the p-values for multiple testing. Default method is the Benjamini-Hochberg method.

verbose

Either 0 (default, no output), 1 (minimum output), or 2 (outout)

Details

Computes p-values from a t-test, using the bioconductor package limma, or with a multidimensional Hotelling T^2 test.

Value

An object of class RNAinteract.

Author(s)

Bernd Fischer

References

~put references to the literature/web site here ~

See Also

RNAinteract-package

Examples

data("sgi")
sgi <- computePValues(sgi, method = "HotellingT2")
# Hotelling T^2 test will provide one p-value for all channels, PV will be the same
# for all channels in this case
PV <- getData(sgi, type="p.value", format="targetMatrix", channel="nrCells")

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(RNAinteract)
Loading required package: abind
Loading required package: locfit
locfit 1.5-9.1 	 2013-03-22
Loading required package: Biobase
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

    IQR, mad, xtabs

The following objects are masked from 'package:base':

    Filter, Find, Map, Position, Reduce, anyDuplicated, append,
    as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
    get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
    match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
    rbind, rownames, sapply, setdiff, sort, table, tapply, union,
    unique, unsplit

Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/RNAinteract/computePValues.Rd_%03d_medium.png", width=480, height=480)
> ### Name: computePValues
> ### Title: compute p-values
> ### Aliases: computePValues
> ### Keywords: manip htest multivariate
> 
> ### ** Examples
> 
> data("sgi")
> sgi <- computePValues(sgi, method = "HotellingT2")
> # Hotelling T^2 test will provide one p-value for all channels, PV will be the same
> # for all channels in this case
> PV <- getData(sgi, type="p.value", format="targetMatrix", channel="nrCells")
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>