Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/hillerlab/CESAR2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Hiller committed Apr 12, 2019
2 parents 79729e5 + 9be8c27 commit bf8b706
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,10 @@ chmod +x jobList
# Convert results into genePred format (excluding 0-bp exons due to complete deletions)
for species in `echo $querySpecies | sed 's/,/ /g'`; do
echo "bed2GenePred.pl $species $outputDir /dev/stdout | awk '{if ($4 != $5) print $0}' > $resultsDir/$species.gp"
echo "bed2GenePred.pl $species $outputDir /dev/stdout | awk '{if (\$4 != \$5) print \$0}' > $resultsDir/$species.gp"
done > jobListGenePred
chmod +x jobListGenePred
mkdir $resultsDir
./jobListGenePred
# This will take ~15 minutes
Expand Down Expand Up @@ -158,9 +159,10 @@ or run it in parallel by using a compute cluster.
After each realignment job succeeded, collect the results as a single genePred file for each query species by running:
```
for species in `echo $querySpecies | sed 's/,/ /g'`; do
echo "bed2GenePred.pl $species $outputDir /dev/stdout | awk '{if ($4 != $5) print $0}' > $resultsDir/$species.gp"
echo "bed2GenePred.pl $species $outputDir /dev/stdout | awk '{if (\$4 != \$5) print \$0}' > $resultsDir/$species.gp"
done > jobListGenePred
chmod +x jobListGenePred
mkdir $resultsDir
./jobListGenePred
```

Expand Down
6 changes: 3 additions & 3 deletions tools/bed2GenePred.pl
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@
my %accListHash = my %hashFromFile = ();
## Collect all exons of that species and convert it to a 2 dimensional hash, the first dimension is the accession, the second is just a number, the value is the line.
my $call = "find $dir -type f -path '*/${species}/*' -exec cat {} \\;";
print "executing '$call' ...\n";
print STDERR "executing '$call' ...\n";
my @results = `$call`;
die "ERROR: $call failed\n" if ($? != 0 || ${^CHILD_ERROR_NATIVE} != 0);
print "gives ", $#results+1, " exons\n";
print STDERR "gives ", $#results+1, " exons\n";
for (my $i = 0; $i<=$#results; $i++) {
my $line = $results[$i];
$line =~s/\s+$//;
Expand Down Expand Up @@ -167,7 +167,7 @@
}
close FO;
`rm $tmpBed $tmpBedFile $tmpFileB2L`;
print "Results for $species are in $genePred\n";
print STDERR "Results for $species are in $genePred\n";

### Sub-routines

Expand Down

0 comments on commit bf8b706

Please sign in to comment.