diff rgedgeR/rgedgeRpaired.xml @ 13:f542654faa3b draft

Uploaded
author fubar
date Sat, 27 Jul 2013 02:18:41 -0400
parents aa528c834664
children 8272815ba8ce
line wrap: on
line diff
--- a/rgedgeR/rgedgeRpaired.xml	Sat Jul 27 01:56:58 2013 -0400
+++ b/rgedgeR/rgedgeRpaired.xml	Sat Jul 27 02:18:41 2013 -0400
@@ -401,7 +401,7 @@
   zN = allN - nzN
   print('# Quantiles for non-zero row counts:',quote=F)
   print(quantile(nzrs,probs=seq(0,1,0.1)),quote=F)
-  if (useNDF == "T")
+  if (useNDF == T)
   {
     gt1rpin3 = rowSums(Count_Matrix/expandAsMatrix(colTotmillionreads,dim(Count_Matrix)) >= 1) >= nscut
     lo = colSums(Count_Matrix[!gt1rpin3,])
@@ -512,7 +512,7 @@
   print(paste('Raw sample read totals',paste(colSums(nonzerod,na.rm=T),collapse=',')))
   nzd = data.frame(log(nonzerod + 1e-2,10))
   boxPlot(rawrs=nzd,cleanrs=log(normData,10),maint='TMM Normalisation',myTitle=myTitle,pdfname="edgeR_raw_norm_counts_box.pdf")
-  write.table(soutput,out_edgeR, quote=FALSE, sep="\t",row.names=F)
+  write.table(soutput,file=out_edgeR, quote=FALSE, sep="\t",row.names=F)
   tt = cbind( 
     Name=as.character(rownames(DGEList\$counts)),
     DE\$table,
@@ -567,7 +567,7 @@
     qqPlot(descr=paste(myTitle,'DESeq2 qqplot'),pvector=rDESeq\$pvalue,outpdf='DESeq2_qqplot.pdf')
     cat("# DESeq top 50\n")
     print.noquote(srDESeq[1:50,])
-    write.table(srDESeq,out_DESeq2, quote=FALSE, sep="\t",row.names=F)
+    write.table(srDESeq,file=out_DESeq2, quote=FALSE, sep="\t",row.names=F)
     topresults.DESeq = rDESeq[which(rDESeq\$padj < fdrthresh), ]
     DESeqcountsindex = which(allgenes %in% rownames(topresults.DESeq))
     DESeqcounts = rep(0, length(allgenes))
@@ -623,14 +623,14 @@
       rownames(rvoom) = rownames(workCM)
       rvoom = cbind(rvoom,NReads=cmrowsums,URL=contigurls)
       srvoom = rvoom[order(rvoom\$P.Value),]
-      write.table(srvoom,out_VOOM, quote=FALSE, sep="\t",row.names=F)
+      cat("# VOOM top 50\n")
+      print(srvoom[1:50,])
+      write.table(srvoom,file=out_VOOM, quote=FALSE, sep="\t",row.names=F)
       # Use an FDR cutoff to find interesting samples for edgeR, DESeq and voom/limma
       topresults.voom = srvoom[which(rvoom\$adj.P.Val < fdrthresh), ]
       voomcountsindex = which(allgenes %in% topresults.voom\$ID)
       voomcounts = rep(0, length(allgenes))
       voomcounts[voomcountsindex] = 1
-      cat("# VOOM top 50\n")
-      print(srvoom[1:50,])
       sink()
   }
 
@@ -671,23 +671,26 @@
 history_gmt=""
 out_edgeR = F
 out_DESeq2 = F
-out_VOOM = F
+out_VOOM = "${out_VOOM}"
 doDESeq2 = $DESeq2.doDESeq2 # make these T or F
 doVoom = $doVoom
 doCamera = F 
 doedgeR = $edgeR.doedgeR
 edgeR_priordf = 0
 
-#if $DESeq2.doDESeq2 == "T":
-  out_DESeq2 = "$out_DESeq2"
-  DESeq_fitType = "$DESeq2.DESeq_fitType"
+
+#if ${doVoom} == "T":
+  out_VOOM = "${out_VOOM}"
 #end if
-#if $edgeR.doedgeR == "T":
-  out_edgeR = "$out_edgeR"
-  edgeR_priordf = $edgeR.edgeR_priordf
+
+#if ${DESeq2.doDESeq2} == "T":
+  out_DESeq2 = "${out_DESeq2}"
+  DESeq_fitType = "${DESeq2.DESeq_fitType}"
 #end if
-#if $doVoom == "T":
-  out_VOOM = "$out_VOOM"
+
+#if ${edgeR.doedgeR} == "T":
+  out_edgeR = "${out_edgeR}"
+  edgeR_priordf = ${edgeR.edgeR_priordf}
 #end if
 
 Out_Dir = "$html_file.files_path"
@@ -700,7 +703,7 @@
 if (org == "") { org = "hg19"}
 fdrtype = "$fdrtype"
 fdrthresh = $fdrthresh
-useNDF = "$useNDF"
+useNDF = $useNDF
 fQ = $fQ # non-differential centile cutoff
 myTitle = "$title"
 subjects = c($subjectids)
@@ -740,7 +743,7 @@
 group = c(rep(TreatmentName,length(TCols)), rep(ControlName,length(CCols)) )             #Build a group descriptor
 group = factor(group, levels=c(ControlName,TreatmentName))
 colnames(Count_Matrix) = paste(group,colnames(Count_Matrix),sep="_")                   #Relable columns
-results = edgeIt(Count_Matrix=Count_Matrix,group=group,out_edgeR=out_edgeR, out_VOOM=out_VOOM, out_DESeq2=out_DESeq2,
+results = edgeIt(Count_Matrix=Count_Matrix,group=group, out_edgeR=out_edgeR, out_VOOM=out_VOOM, out_DESeq2=out_DESeq2,
                  fdrtype='BH',priordf=edgeR_priordf,fdrthresh=0.05,outputdir='.',
                  myTitle=myTitle,useNDF=F,libSize=c(),filterquantile=fQ,subjects=c(),
                  doDESeq2=doDESeq2,doVoom=doVoom,doCamera=doCamera,doedgeR=doedgeR,org=org,