Hello!

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

Note that updates take place every 10 minutes, commits may not be seen immediately.
Now needs a supplied species list file. No longer needs to be manually edited to...
authorelserj <elserj@localhost>
Fri, 28 Jun 2013 23:41:08 +0000 (23:41 +0000)
committerelserj <elserj@localhost>
Fri, 28 Jun 2013 23:41:08 +0000 (23:41 +0000)
svn path=/; revision=490

interactome_scripts/supercluster.pl

index d30dbef525c34c37fc90ee88d2763da4ae38bbea..df5f2a0b1707922b27985c25ef1818a12ae0f8ca 100755 (executable)
@@ -35,6 +35,14 @@ if(-e "$ENV{HOME}/scripts/jaiswallab/interactome_scripts/find_species.pl") {
        require "$ENV{HOME}/bin/find_species.pl";
 }
 
+# check for arguments and explain usage
+if ($#ARGV !=0) {
+       print "usage: supercluster.pl species_list_file\n";
+       exit;
+}
+
+my $spec_file = $ARGV[0];
+
 my $dbh = DbiFloret::dbconnect;
        
 print "Minimum paralogy score: ";
@@ -44,7 +52,16 @@ if($min_score eq "") {
        $min_score = 0;
 }
 
-       
+my @species;
+
+open(SPECFILE, "$spec_file");
+
+while(<SPECFILE>) {
+               my $line = $_;
+               chomp $line;
+               push (@species, $line);
+}
+
        
 #### Note to self ####
 ## To not have multiple values in mysql table, use insert ignore instead of insert.  Or use replace.
@@ -69,8 +86,6 @@ my $super_id = 0; #initialize the super cluster id
 my %super_hash;
 my %big_count_hash;
        
-my @species  = ("Arabidopsis_lyrata", "Arabidopsis_thaliana", "Carica_papaya", "Citrus_clementina", "Citrus_sinensis", "Eucalyptus_grandis", "Fragaria_vesca", "Malus_domestica", "Oryza_sativa", "Populus_trichocarpa", "Prunus_persica", "Vitis_vinifera");
-#my @species = all_species_array();
 my $num_species = @species;
 
 for (my $i=0; $i<$num_species-1; $i++) {