[Patchwork-commits] r172 - pkg/patchwork/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Jun 5 16:12:24 CEST 2013


Author: sebastian_d
Date: 2013-06-05 16:12:24 +0200 (Wed, 05 Jun 2013)
New Revision: 172

Modified:
   pkg/patchwork/R/patchwork.alleledata.r
Log:
fix to choosing correct DBSNP list for different chromosome naming conventions. (chr1 or 1)

Modified: pkg/patchwork/R/patchwork.alleledata.r
===================================================================
--- pkg/patchwork/R/patchwork.alleledata.r	2013-06-05 12:18:30 UTC (rev 171)
+++ pkg/patchwork/R/patchwork.alleledata.r	2013-06-05 14:12:24 UTC (rev 172)
@@ -74,14 +74,14 @@
 	hgcheck = strsplit(line,"\t")
 
 	#Sometimes chr1 isnt first in the pileup file, traverse until you get to chr1 to see if hg18 or hg19 should be applied.
-	while(hgcheck[[1]][1] != "chr1")
+	while((hgcheck[[1]][1] != "chr1") || (hgcheck[[1]][1] != "1"))
 		{
 		line = readLines(con,1)
 		hgcheck = strsplit(line,"\t")
 		}
 	close(con)
 
-
+	#Check pos to see which Snps should be used, hg18 or hg19
 	if (as.numeric(hgcheck[[1]][2]) <= 10000)
 		{
 		data(commonSnpsHG18,package="patchworkData")



More information about the Patchwork-commits mailing list