diff rapsodyn/PileupVariant.pl @ 0:442a7c88b886 draft

Uploaded
author mcharles
date Wed, 10 Sep 2014 09:18:15 -0400
parents
children 3f7b0788a1c4
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/rapsodyn/PileupVariant.pl	Wed Sep 10 09:18:15 2014 -0400
@@ -0,0 +1,19 @@
+#!/usr/bin/perl
+use strict;
+
+my $inputfile = $ARGV[0];
+open(IF, $inputfile)  or die("Can't open $inputfile\n");
+
+#Extraction des variants
+my $nb_line=0;
+while (my $line=<IF>){
+	my $test = $line;
+	$test =~ s/\$//g; #the read start at this position
+	$test =~ s/\^.//g; #the read end at this position followed by quality char
+	my @field = split(/\s+/,$test);
+	
+	if ($field[4]=~/[ATGCN]/i){
+		print $line;
+	}
+}
+close(IF);