my $taxon = $ARGV[3]; unless($taxon){ $taxon = "";#default is blank } $annotation .= "\t$taxon"; my @taxList = split(/\|/, $taxon); open(tax_file, "..".$slash."dataset".$slash."taxonomy.tab") or die "couldn't open taxonomy.tab"; #my @taxR = ; my %taxR; if($taxon){ while(){ foreach my $tempTax (@taxList){ if($_ =~ m/$tempTax/i){ my @tempTax = split(/\t/, $_); $taxR{$tempTax[1]} = 1; } } } } close tax_file;