RPS.learn(RPS) | R Documentation |
Use the reference data to compute correlation rho across labs
RPS.learn(MAQC, lab.info, sample.info)
MAQC |
microarray data include several labs |
lab.info |
a vector provides that an array belongs to which lab.Its length equals the number of arrays |
sample.info |
a vector provides that an array belongs to which sample.Its length equals the number of arrays |
How to specify sample informaiton and lab information for the microarry data?
If the mircoarray data include 3 labs(L1,L2,L3) and 2 samples (S1,S2) and 2 replicates(R1,R2),
and the columns of the expression data are arranged like(Labs first,samples second , and replicates) :
L1S1R1 L1S1R2 L1S2R1 L1S2R2 L2S1R1 L2S1R2 L2S2R1 L2S2R2 L3S1R1 L3S1R2 L3S2R1 L3S2R2
then
lab.info=c(1,1,1,1,2,2,2,2,3,3,3,3) #length 2*3*2
sample.info=c(1,1,2,2,1,1,2,2,1,1,2,2) #length 2*3*2
corr.Labs |
a list contain correlation rho across labs |
var.matrix |
variance information from the two random effects models. |
Guixian Lin and Sheng Zhong
##use two vector train.lab.info and train.sample.info to specify the array belongs which lab and sample. ##For example,if there are 3 labs and 2 samples and 5 replicates in the reference data(Here is MAQC data) ##and the order of the arrays are replicates,samples and labs ,then n.rep=5 #replicates for one sample in one lab n.s=4 #samples' number n.lab=3 #labs' number train.lab.info=c(rep(1,n.rep*n.s),rep(2,n.rep*n.s),rep(3,n.rep*n.s)) # 3 labs,providing the lab information that each array/column belongs train.sample.info=rep(c(rep(1,n.rep),rep(2,n.rep),rep(3,n.rep),rep(4,n.rep)),3) # 4 samples ,providing the samples information that each array/column belongs MAQC.train=RPS.readnew("ABI_12091.txt",transformed=F) ##MAQC.train dataset include these following columns:one probe set name,and expressions for replicates,samples,and labs corr=RPS.learn(MAQC.train[,2:(n.rep*n.s*n.lab+1)],train.lab.info,train.sample.info); ##get the correlations information between labs,and the returned values is a list which include pho and variance.Use the returned values to generate "samples mean" for new labs summary(corr$corr.Labs) ##summary of correlations for each probe set across labs