0
|
1 #!/usr/bin/perl -w
|
|
2 use strict;
|
|
3 use warnings;
|
|
4
|
|
5 my $STpmlst = "";
|
|
6
|
|
7 my $path = $ARGV[0];
|
|
8 my $seq = $ARGV[1];
|
|
9 my $scheme = $ARGV[2];
|
|
10
|
|
11
|
|
12 open PMLST, "python3 $path/pmlst/pmlst.py -i $seq -s $scheme -p $path/pmlst/pmlst_db/ -mp $path/blastn |";
|
|
13 while (<PMLST>) {
|
|
14 chomp ($_);
|
|
15 if ($_ =~ "sequence_type") {
|
|
16 #print "ST:$_ \n";
|
|
17 my @table = split (/:/,$_);
|
|
18 $STpmlst = $table [1];
|
|
19 #chomp ($STpmlst); $STpmlst = chop($STpmlst);
|
|
20 $STpmlst =~ s/\s+//;
|
|
21 $STpmlst = substr($STpmlst,1);
|
|
22 my @table2 = split (/'/,$STpmlst);
|
|
23 $STpmlst = $table2[0];
|
|
24 #print "$STpmlst\n" ;
|
|
25 }
|
|
26 }
|
|
27
|
|
28 #print "Sequence\tSequence Type (pMLST)\n" ;
|
|
29 print "pMLST for $seq:\t$STpmlst\n" ;
|