Skip to content

Commit

Permalink
Update to CM profiles and fixed a small bug with get_unique_features.pl
Browse files Browse the repository at this point in the history
  • Loading branch information
biocoder committed Feb 12, 2018
1 parent 6814ecb commit 49ba266
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 11 deletions.
Binary file added NGS-Utils/.lncRNApipe.depbin/Rfam.cm.1_1.bz2
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/Rfam.cm.1_1.i1f
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/Rfam.cm.1_1.i1i
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/Rfam.cm.1_1.i1m.bz2
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/Rfam.cm.1_1.i1p
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/darwin_cmscan
Binary file not shown.
Binary file added NGS-Utils/.lncRNApipe.depbin/linux_cmscan
Binary file not shown.
2 changes: 1 addition & 1 deletion NGS-Utils/README.pod
Original file line number Diff line number Diff line change
Expand Up @@ -831,6 +831,6 @@ This program is distributed under the Artistic License 2.0.

=head1 DATE

Feb-07-2018
Feb-12-2018

=cut
9 changes: 5 additions & 4 deletions NGS-Utils/annotate_final_ncRNAs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

# (C) Kranti Konganti
# This program is distributed as Artistic License 2.0.
# 11/15/2017
# 02/12/2018
# Coordinate with lncRNApipe output to parse out and add Infernal annotation to final ncRNA transcripts.

# $LastChangedBy: konganti $ =~ m/.+?\:(.+)/;
# $LastChangedDate: 2017-11-15 14:45:27 -0500 (Wed, 15 November 2017) $ =~ m/.+?\:(.+)/;
# $LastChangedRevision: 2707 $ =~ m/.+?\:\s*(.*)\s*.*/;
# $LastChangedDate: 2018-02-12 09:45:27 -0500 (Mon, 12 February 2018) $ =~ m/.+?\:(.+)/;
# $LastChangedRevision: 2708 $ =~ m/.+?\:\s*(.*)\s*.*/;
# $AUTHORFULLNAME = 'Kranti Konganti';

if [ -z "$FINAL_GTF" ] ||
Expand All @@ -26,7 +26,8 @@ grep noncoding $CPC_TXT_OUT | cut -f 1 | sort -n | uniq | while read unetrid; do
contig_en=`grep -P "\ttranscript\t.+?\"$trid\".+" $FINAL_GTF | awk '{print $5}'`;
trlen=`grep -P "\"$trid\"" $FINAL_GTF | grep -oP 'transcript_length \"\d+\"' | head -n 1 | perl -e '\$line = <>; if (\$line =~ m/.+?(\d+)/) {print \$1;}'`;
hitlen=`grep -P "\s+$trid\s+" $CM_TXT_OUT | grep -P "\\s+\!\\s+" | sort -k15,15nr | uniq | head -n 1 | awk '{if(\$10=="+") print \$9-\$8; else print \$8-\$9;}'`;
annot=`grep -P "\s+$trid\s+" $CM_TXT_OUT | grep -P "\\s+\!\\s+" | sort -k15,15nr | uniq | awk '{$1=""; sc=$15; for(i=3;i<=17;i++) $i=""; if (length($0) != 0) print $0, " | BitScore: ",sc}' | cut -d " " -f 2- | sed -e 's/\s\+/ /g' | head -n 1`;
annot=`grep -P "\s+$trid\s+" $CM_TXT_OUT | grep -P "\\s+\!\\s+" | sort -k15,15nr | uniq | awk '{sc=$15; for(i=1;i<=17;i++); if (length($0) != 0) print "Match: ", $1, " | BitScore: ", sc}' | sed -e 's/\s\+/ /g' | head -n 1`;
#annot=`grep -P "\s+$trid\s+" $CM_TXT_OUT | grep -P "\\s+\!\\s+" | sort -k15,15nr | uniq | awk '{$1=""; sc=$15; for(i=3;i<=17;i++) $i=""; if (length($0) != 0) print $0, " | BitScore: ",sc}' | cut -d " " -f 2- | sed -e 's/\s\+/ /g' | head -n 1`;

if [ -z "$trlen" ] || [ -z "$hitlen" ]; then
calc_cov=0.0;
Expand Down
10 changes: 7 additions & 3 deletions NGS-Utils/get_unique_features.pl
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
use Set::IntervalTree;

my ($LASTCHANGEDBY) = q$LastChangedBy: konganti $ =~ m/.+?\:(.+)/;
my ($LASTCHANGEDDATE) = q$LastChangedDate: 2016-01-11 12:48:27 -0500 (Mon, 1 Jan 2016) $ =~ m/.+?\:(.+)/;
my ($VERSION) = q$LastChangedRevision: 0605 $ =~ m/.+?(\d+)/;
my ($LASTCHANGEDDATE) = q$LastChangedDate: 2018-02-12 10:48:27 -0500 (Mon, 12 Feb 2018) $ =~ m/.+?\:(.+)/;
my ($VERSION) = q$LastChangedRevision: 0606 $ =~ m/.+?(\d+)/;
my $AUTHORFULLNAME = 'Kranti Konganti';

my $io = IO::Routine->new();
Expand Down Expand Up @@ -199,6 +199,8 @@ sub compare_feat {
while (my $line = <$s_fh>) {

chomp $line;
next if ($line =~ m/^\W/);

my ($left_coords, $right_coords) = [];

$line = $io->strip_leading_and_trailing_spaces($line);
Expand Down Expand Up @@ -261,6 +263,8 @@ sub compare_feat {
my $insert_line = 0;
while (my $line = <$c_fh>) {
chomp $line;
next if ($line =~ m/^\W/);

$line = $io->strip_leading_and_trailing_spaces($line);

my @cols = split/\t/, $line;
Expand Down Expand Up @@ -653,6 +657,6 @@ =head1 COPYRIGHT
=head1 DATE
Jan-11-2016
Feb-12-2018
=cut
11 changes: 8 additions & 3 deletions NGS-Utils/lncRNApipe
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ use Data::Dumper;
Getopt::Long::Configure('prefix=--');

my ($LASTCHANGEDBY) = q$LastChangedBy: konganti $ =~ m/.+?\:(.+)/;
my ($LASTCHANGEDDATE) = q$LastChangedDate: 2018-02-07 09:27:27 -0500 (Wed, 07 February 2018) $ =~ m/.+?\:(.+)/;
my ($VERSION) = q$LastChangedRevision: 1.2.1 $ =~ m/.+?\:\s*(.*)\s*.*/;
my ($LASTCHANGEDDATE) = q$LastChangedDate: 2018-02-12 09:27:27 -0500 (Mon, 12 February 2018) $ =~ m/.+?\:(.+)/;
my ($VERSION) = q$LastChangedRevision: 1.2.2 $ =~ m/.+?\:\s*(.*)\s*.*/;
my $AUTHORFULLNAME = 'Kranti Konganti';

my ($help, $quiet, $setup, $get_uq_sc_opts,
Expand Down Expand Up @@ -822,6 +822,11 @@ sub run_lncRNApipe {

# \x{2633}
if ($lncRNApipe_succ) {
$io->warning('INFERNAL authors state the following:' .
"\n\n" . 'We recommend that you use Rfam/Infernal for vertebrate genome annotation with extreme caution! ' .
"\n" . 'Nevertheless, Rfam/Infernal does tell us about important sequence similarities that are effectively undetectable by other means. ' .
"\n" . 'However, in complex eukaryotic genomes, it is important to treat hits as sequence similarity ' .
"\n" . 'information (much as you might treat BLAST hits), rather than as evidence of bona fide ncRNA genes.', 'INFO!!');
$io->c_time("\x{2632}\x{2634} lncRNApipe Pipeline finished!");
}
else {
Expand Down Expand Up @@ -3862,6 +3867,6 @@ This program is distributed under the Artistic License 2.0.
=head1 DATE
Feb-07-2018
Feb-12-2018
=cut

0 comments on commit 49ba266

Please sign in to comment.