How to modify the source code in samr? I want to do the TMM normalization.
I had the following:
SAMseq.test = SAMseq(countdata1, finaldata1$Group, geneid=as.character(rownames(countdata1)),
genenames=as.character(rownames(countdata1)),
resp.type="Two class unpaired",nperms=1000, random.seed = 1234, fdr.output=0.2)
print(SAMseq.test)
In case of TMM normalization, one can manipulate the function, but how?
"samr.estimate.depth" of the source code as below and then resintall the package with the new source file.
# samr.estimate.depth
# function (x)
# {
# library(edgeR)
# cmeans <- calcNormFactors(x) * colSums(x)
# depth <- cmeans/mean(cmeans)
# return(depth)
# }
# <environment: namespace:samr>
If anyone knows how?
Thanks a lot!