cond.fyx: Compute the ECF-statistics measuring the differential...

Description Usage Arguments Value Author(s) References Examples

View source: R/cond.fyx.R

Description

A function to calculate the expected conditional F-statistics as a measure of differential gene co-expression patterns.

Usage

1
cond.fyx(data.y, data.x, type)

Arguments

data.y

A vector containing the expression values of one gene across two datasets

data.x

A vector containing the expression values of another gene across two datasets

type

A vector indicating the type of each sample, whose length is the sum of the sample sizes of data.y and data.x

Value

The ECF-statistics of a specific gene

Author(s)

Yinglei Lai

References

http://bioinformatics.oxfordjournals.org/content/20/17/3146.long

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
#load two of the simulated datasets

data(simulated_data)
set1_data<-simulated_data[[1]]
control_data<-simulated_data[[7]]

num_sample <- dim(set1_data)[1]
num_gene <- dim(set1_data)[2]

type <- c(rep(0,num_sample),rep(1,num_sample))

#Compute the ECF-statistic for the gene pair of gene 1 and gene 2

i=1
j=2
data.x <- c(set1_data[,i],control_data[,i])
data.y <- c(set1_data[,j],control_data[,j])

ecf <- ( cond.fyx(data.y,data.x,type) + 
        cond.fyx(data.x,data.y,type) )/2

COSINE documentation built on May 1, 2019, 10:21 p.m.