#simulate some data sets: matrices of log-abundance levels
nsam<-25 #number of individuals
nfeat<-50 #number of features (metabolites, genes,...)
diffs<-c(1,4) #features with differential log-abundance levels
lfc<-5 #differential quantity
# create data sets:
x <- matrix(runif(nfeat*nsam), nrow = nfeat, ncol = nsam) #case
y <- matrix(runif(nfeat*nsam), nrow = nfeat, ncol = nsam) #control
x[diffs,] <- x[diffs,] + lfc
# moderated t-stat estimators: ----------
z1 <- other.est (x=x,y=y,opt="limma")
z2 <- other.est (x=x,y=y,opt="pseudo")
z3 <- other.est (x=x,y=y,opt="lfdr0",pval.fun="t.test")
Run the code above in your browser using DataLab