Hello!

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

Note that updates take place every 10 minutes, commits may not be seen immediately.
Scripts that can be used together to run inParanoid as an SGE batch array style job...
authorelserj <elserj@localhost>
Tue, 16 Dec 2014 23:46:49 +0000 (23:46 +0000)
committerelserj <elserj@localhost>
Tue, 16 Dec 2014 23:46:49 +0000 (23:46 +0000)
svn path=/; revision=598

interactome_scripts/create_fasta_list.sh [new file with mode: 0755]
interactome_scripts/run_array_job_by_id.pl [new file with mode: 0755]
interactome_scripts/run_inparanoid_single.sh [new file with mode: 0755]

diff --git a/interactome_scripts/create_fasta_list.sh b/interactome_scripts/create_fasta_list.sh
new file mode 100755 (executable)
index 0000000..08f5988
--- /dev/null
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+outfile="fasta_job_list.txt"
+
+counter=1
+
+lsarray=(`ls *.fa`)
+len=${#lsarray[@]}
+
+for (( i=0; i<$len; i++))
+do
+        for (( j=$i+1; j<$len; j++ ))
+        do
+               echo "$counter  ${lsarray[$i]}  ${lsarray[$j]}" >> $outfile
+               ((counter++))
+       done
+done
+
diff --git a/interactome_scripts/run_array_job_by_id.pl b/interactome_scripts/run_array_job_by_id.pl
new file mode 100755 (executable)
index 0000000..4340cc4
--- /dev/null
@@ -0,0 +1,31 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+
+if($#ARGV != 1) {
+       print "usage: run_array_job_by_id.pl job_id id_mapping_file\n";
+       exit;
+}
+
+my $id = $ARGV[0];
+my $mappingFile = $ARGV[1];
+
+my %map_hash;
+
+open(MAPFILE, "$mappingFile");
+while(<MAPFILE>) {
+               my $line = $_;
+               chomp $line;
+               my ($map_id, $species_1, $species_2) = split(/\s+/, $line);
+               $map_hash{$map_id} = "$species_1\t$species_2";
+}
+
+close(MAPFILE);
+
+my ($species_1, $species_2) = split(/\s+/, $map_hash{$id});
+
+system "run_inparanoid_single.sh $species_1 $species_2\n";
+
+
diff --git a/interactome_scripts/run_inparanoid_single.sh b/interactome_scripts/run_inparanoid_single.sh
new file mode 100755 (executable)
index 0000000..6b32d1b
--- /dev/null
@@ -0,0 +1,30 @@
+#!/bin/bash
+
+currentdir=(`pwd`)
+date=(`date +%m_%d_%y`)
+directory=/lemma/inparanoid_data/$date
+mkdir -p $directory
+
+file1=$1
+file2=$2
+
+dirname=$directory/${file1}_______${file2}
+mkdir -p $dirname
+fasta_header_fix.pl ${file1} $dirname/${file1}
+fasta_header_fix.pl ${file2} $dirname/${file2}
+cd $dirname
+cp /home/bpp/elserj/Orthology_software/inparanoid/inparanoid_fixed.pl ./
+cp /home/bpp/elserj/Orthology_software/inparanoid/blast_parser.pl ./
+cp /home/bpp/elserj/Orthology_software/inparanoid/BLOSUM62 ./
+cp /home/bpp/elserj/Orthology_software/inparanoid/InparanoidXMLCreator.pl ./
+cp /home/bpp/elserj/Orthology_software/inparanoid/seqstat.jar ./
+
+cp /lemma/inparanoid_data/07_22_14/sqltables/sqltable.Triticum_urartu_gramene_ftp_1_17_14.fa-Zea_mays_phytozome_mart_9_9_13.fa ./
+
+inparanoid_fixed.pl ${file1} ${file2}
+
+mkdir -p $directory/sqltables
+mv sqltable.${file1}-${file2} $directory/sqltables
+
+cd ..
+rm -r $dirname