Hello!

To see the file structure, click on "tree".

Note that updates take place every 10 minutes, commits may not be seen immediately.
Fix file handle name and wildcard db query
authorelserj <elserj@localhost>
Tue, 16 Dec 2014 23:35:39 +0000 (23:35 +0000)
committerelserj <elserj@localhost>
Tue, 16 Dec 2014 23:35:39 +0000 (23:35 +0000)
svn path=/; revision=595

interactome_scripts/make_fasta_from_gene_list.pl

index 45be6a4eb3a65b3e4aa8b3fca3a9536d57a8e96c..bcfe43c690a3f645165e841c790b8fbd06a44007 100755 (executable)
@@ -31,18 +31,18 @@ my $safe_species = $dbh->quote_identifier($species);
 
 my $sth_get_sequence = $dbh->prepare("select sequence from $safe_species where gene_id like ?");
 
-open(outputfh, ">$ARGV[2]");
+open(OUTPUTFH, ">$ARGV[2]");
 
 foreach my $gene (@genes) {
-       $sth_get_sequence->execute($gene);
-       print outputfh ">$gene\n";
+       $sth_get_sequence->execute($gene . "%");
+       print OUTPUTFH ">$gene\n";
        while (my @line = $sth_get_sequence->fetchrow_array) {
                my $line = $line[0];
                my $len = length($line);
                for (my $pos=0; $pos < $len; $pos+=80) {
-                       print outputfh substr($line, $pos, 80), "\n";
+                       print OUTPUTFH substr($line, $pos, 80), "\n";
                }
        }
 }
-close(outputfh);
+close(OUTPUTFH);