#! /usr/bin/perl use strict; use warnings; my ( $best_X, $best_Y, $block1, $block2, $counter, $tq, $pp, $pp2, $pz, $pz2, $position1, $position2, $resH, $nTE2 ); #keep counts of matches to check for unique match $counter++ if ( $best_X <= 110 && $block1 <= 110 || $best_Y <= 110 && $block2 <= 110 ); if ($counter == 1){ $tq = "unique_match"; } elsif ($best_X <= 100){ if ($block1 <= 100){ $pp = "best_match+TE"; } elsif ($block2 <= 50 && $position2 < 5){ $pp2 = "best_match-TE"; } } else{ next; # are we in a loop? } if ($best_Y <= 100){ if ($block1 >= 70){ $pz = "best_match+TE"; } elsif ($block1 <= 50 && $position1 >= 50){ # block2? $pz2 = "best_match-TE"; } } else{ next; } #} perl complains about this one $resH = $tq; if ($pp eq $pz){ $resH = "best_match+TE"; } elsif ($nTE2 eq $pp2 || $nTE2 eq $pz2){ $resH = "best_match -TE" }