Mercurial > repos > fubar > differential_count_models
comparison rgedgeRpaired_nocamera.xml @ 80:335abf087bc5 draft
Uploaded
author | fubar |
---|---|
date | Wed, 26 Feb 2014 01:43:53 -0500 |
parents | 17d82de7a2d9 |
children | f86cb6b724ee |
comparison
equal
deleted
inserted
replaced
79:17d82de7a2d9 | 80:335abf087bc5 |
---|---|
592 } | 592 } |
593 } | 593 } |
594 print.noquote(paste('Using samples:',paste(colnames(workCM),collapse=','))) | 594 print.noquote(paste('Using samples:',paste(colnames(workCM),collapse=','))) |
595 print.noquote('Using design matrix:') | 595 print.noquote('Using design matrix:') |
596 print.noquote(mydesign) | 596 print.noquote(mydesign) |
597 if (doedgeR) { | 597 if (doedgeR == T) { |
598 sink('edgeR.log') | 598 sink('edgeR.log') |
599 #### Setup DGEList object | 599 #### Setup DGEList object |
600 DGEList = DGEList(counts=workCM, group = group) | 600 DGEList = DGEList(counts=workCM, group = group) |
601 DGEList = calcNormFactors(DGEList) | 601 DGEList = calcNormFactors(DGEList) |
602 if (robust_meth == 'ordinary') { | 602 if (robust_meth == 'ordinary') { |
606 | 606 |
607 comdisp = DGEList\$common.dispersion | 607 comdisp = DGEList\$common.dispersion |
608 estpriorn = getPriorN(DGEList) | 608 estpriorn = getPriorN(DGEList) |
609 print(paste("Common Dispersion =",comdisp,"CV = ",sqrt(comdisp),"getPriorN = ",estpriorn),quote=F) | 609 print(paste("Common Dispersion =",comdisp,"CV = ",sqrt(comdisp),"getPriorN = ",estpriorn),quote=F) |
610 } else { | 610 } else { |
611 DGEList = estimateGLMRobustDisp(DGEList,design=mydesign, prior.df = edgeR_priordf, maxit = 6, residual.type = robust_meth) | 611 DGEList = estimateGLMRobustDisp(DGEList,design=mydesign, prior.df = edgeR_priordf, maxit = 6, residual.type = robust_meth) |
612 } | 612 } |
613 } | 613 |
614 | |
614 DGLM = glmFit(DGEList,design=mydesign) | 615 DGLM = glmFit(DGEList,design=mydesign) |
615 DE = glmLRT(DGLM,coef=ncol(DGLM\$design)) # always last one - subject is first if needed | 616 DE = glmLRT(DGLM,coef=ncol(DGLM\$design)) # always last one - subject is first if needed |
616 efflib = DGEList\$samples\$lib.size*DGEList\$samples\$norm.factors | 617 efflib = DGEList\$samples\$lib.size*DGEList\$samples\$norm.factors |
617 normData = (1e+06*DGEList\$counts/efflib) | 618 normData = (1e+06*DGEList\$counts/efflib) |
618 uoutput = cbind( | 619 uoutput = cbind( |
816 history_gmt_name = "" | 817 history_gmt_name = "" |
817 out_edgeR = F | 818 out_edgeR = F |
818 out_DESeq2 = F | 819 out_DESeq2 = F |
819 out_VOOM = "$out_VOOM" | 820 out_VOOM = "$out_VOOM" |
820 edgeR_robust_meth = "ordinary" # control robust deviance options | 821 edgeR_robust_meth = "ordinary" # control robust deviance options |
821 doDESeq2 = F | 822 doDESeq2 = $DESeq2.doDESeq2 |
822 doVoom = $doVoom | 823 doVoom = $doVoom |
823 doCamera = F | 824 doCamera = F |
824 doedgeR = $edgeR.doedgeR | 825 doedgeR = $edgeR.doedgeR |
825 edgeR_priordf = 10 | 826 edgeR_priordf = 10 |
826 | 827 |