Description Usage Arguments Value References Examples
Algorithm for the simultaneous estimation of multiple related networks. Some of the functions utilized are a modified version of functions contained in the R package randomForest (A. Liaw and M. Wiener, 2002).
1 | JRF(X, ntree, mtry,genes.name)
|
X |
List object containing expression data for each class, |
ntree |
numeric value: number of trees. |
mtry |
numeric value: number of predictors to be sampled at each node. |
genes.name |
vector containing genes name. The order needs to match the rows of |
A matrix with I
rows and C + 2
columns where I
is the total number of gene-gene interactions and C
is the number of classes. The first two columns contain gene names for each interaction while the remaining columns contain importance scores for different classes.
Petralia, F., Song, WM., Tu, Z. and Wang, P., A New Method for Joint Network Analysis Reveals Common and Different Co-Expression Patterns Among Genes and Proteins in Breast Cancer, submitted
A. Liaw and M. Wiener (2002). Classification and Regression by randomForest. R News 2, 18–22.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | # --- Derive weighted networks via JRF
nclasses=2 # number of data sets / classes
n1<-n2<-20 # sample size for each data sets
p<-5 # number of variables (genes)
genes.name<-paste("G",seq(1,p),sep="") # genes name
# --- Generate data sets
data1<-matrix(rnorm(p*n1),p,n1) # generate data1
data2<-matrix(rnorm(p*n2),p,n1) # generate data2
# --- Standardize variables to mean 0 and variance 1
data1 <- t(apply(data1, 1, function(x) { (x - mean(x)) / sd(x) } ))
data2 <- t(apply(data2, 1, function(x) { (x - mean(x)) / sd(x) } ))
# --- Run JRF and obtain importance score of interactions for each class
out<-JRF(list(data1,data2),mtry=round(sqrt(p-1)),ntree=1000,genes.name)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.