Browse code

git-svn-id: file:///home/git/hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/crlmm@49013 bc3139a8-67e5-0310-9ffc-ced21a209358

unknown authored on 25/08/2010 05:08:54
Showing 2 changed files

... ...
@@ -546,5 +546,5 @@ function (which expects ff objects and supports parallel processing)
546 546
 2010-08-25 M. Ritchie 1.7.12
547 547
 ** Renamed functions readIdatFiles2() -> readIdatFiles(), RGtoXY2() -> RGtoXY(), preprocessInfinium2v2() -> preprocessInfinium2(), crlmmIllumina2() -> crlmmIllumina().  These make use of ff objects to store data.
548 548
 ** Exported crlmmIlluminaV2(), which combines reading in of idats and genotyping in one.  Also added a man page for this function
549
-** Added a check for whether an object is an 'ff_matrix' before running open() or close() to several functions.  Added close() statements to readIdatFiles(), RGtoXY() and stripNormalize().  Added open() statement to stripNormalize().
549
+** Added close() statements to readIdatFiles(), RGtoXY() and stripNormalize().  Added open() statement to stripNormalize().
550 550
 ** tidied up crlmm-illumina.R, removing commented out code.
... ...
@@ -142,11 +142,11 @@ readIdatFiles <- function(sampleSheet=NULL,
142 142
 	       protocolData(RG)[["ScanDate"]] = dates$scan
143 143
        }
144 144
        storageMode(RG) = "lockedEnvironment"
145
-       if(class(RG@assayData$R)[1]=="ff_matrix") {
145
+#       if(class(RG@assayData$R)[1]=="ff_matrix") {
146 146
          close(RG@assayData$R)
147 147
          close(RG@assayData$G)
148 148
          close(RG@assayData$zero)         
149
-       }
149
+#       }
150 150
        RG
151 151
 }
152 152
 
... ...
@@ -498,11 +498,11 @@ RGtoXY = function(RG, chipType, verbose=TRUE) {
498 498
   XY@assayData$zero[infI,] = 0  
499 499
   gc()
500 500
 
501
-  if(class(XY@assayData$X)[1]=="ff_matrix") {
501
+#  if(class(XY@assayData$X)[1]=="ff_matrix") {
502 502
     close(XY@assayData$X)
503 503
     close(XY@assayData$Y)
504 504
     close(XY@assayData$zero)
505
-  }
505
+#  }
506 506
   
507 507
 #  storageMode(XY) = "lockedEnvironment"
508 508
   XY
... ...
@@ -531,10 +531,10 @@ stripNormalize = function(XY, useTarget=TRUE, verbose=TRUE) {
531 531
     if (getRversion() > '2.7.0') pb <- txtProgressBar(min=0, max=max(stripnum), style=3)
532 532
   }
533 533
   
534
-  if(class(XY@assayData$X)[1]=="ff_matrix") {
534
+#  if(class(XY@assayData$X)[1]=="ff_matrix") {
535 535
     open(XY@assayData$X)
536 536
     open(XY@assayData$Y)
537
-  }
537
+#  }
538 538
   for(s in 1:max(stripnum)) {
539 539
     if(verbose) {
540 540
       if (getRversion() > '2.7.0') setTxtProgressBar(pb, s)
... ...
@@ -554,10 +554,10 @@ stripNormalize = function(XY, useTarget=TRUE, verbose=TRUE) {
554 554
     rm(subX, subY, tmp, sel)
555 555
     gc()
556 556
   }
557
-  if(class(XY@assayData$X)[1]=="ff_matrix") {
557
+#  if(class(XY@assayData$X)[1]=="ff_matrix") {
558 558
     close(XY@assayData$X)
559 559
     close(XY@assayData$Y)
560
-  }
560
+#  }
561 561
   
562 562
   if(verbose)
563 563
     cat("\n")
... ...
@@ -694,14 +694,14 @@ preprocessInfinium2 <- function(XY, mixtureSampleSize=10^5,
694 694
     t0 <- proc.time()-t0
695 695
     if(verbose) message("Used ", round(t0[3],1), " seconds to save ", snpFile, ".")
696 696
   }
697
-  if(class(A)[1]=="ff_matrix") {
697
+#  if(class(A)[1]=="ff_matrix") {
698 698
     close(A)
699 699
     close(B)
700 700
     close(zero)
701 701
     close(SKW)
702 702
     close(mixtureParams)
703 703
     close(SNR)
704
-  }
704
+#  }
705 705
   return(res)
706 706
 }
707 707