line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Bio::MUST::Apps::TwoScalp::Seqs2Profile; |
2
|
|
|
|
|
|
|
# ABSTRACT: internal class for two-scalp tool |
3
|
|
|
|
|
|
|
# CONTRIBUTOR: Amandine BERTRAND <amandine.bertrand@doct.uliege.be> |
4
|
|
|
|
|
|
|
# CONTRIBUTOR: Valerian LUPO <valerian.lupo@doct.uliege.be> |
5
|
|
|
|
|
|
|
$Bio::MUST::Apps::TwoScalp::Seqs2Profile::VERSION = '0.231010'; |
6
|
1
|
|
|
1
|
|
8
|
use Moose; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
7
|
|
7
|
1
|
|
|
1
|
|
7857
|
use namespace::autoclean; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
9
|
|
8
|
|
|
|
|
|
|
|
9
|
1
|
|
|
1
|
|
102
|
use autodie; |
|
1
|
|
|
|
|
31
|
|
|
1
|
|
|
|
|
15
|
|
10
|
1
|
|
|
1
|
|
6176
|
use feature qw(say); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
106
|
|
11
|
|
|
|
|
|
|
|
12
|
1
|
|
|
1
|
|
7
|
use Smart::Comments '###'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
10
|
|
13
|
|
|
|
|
|
|
|
14
|
1
|
|
|
1
|
|
834
|
use List::AllUtils qw(part); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
71
|
|
15
|
|
|
|
|
|
|
|
16
|
1
|
|
|
1
|
|
6
|
use Bio::MUST::Core; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
39
|
|
17
|
1
|
|
|
1
|
|
6
|
use Bio::MUST::Core::Constants qw(:gaps); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
170
|
|
18
|
1
|
|
|
1
|
|
8
|
use Bio::MUST::Core::Utils qw(secure_outfile); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
64
|
|
19
|
|
|
|
|
|
|
|
20
|
1
|
|
|
1
|
|
8
|
use aliased 'Bio::MUST::Core::Ali'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
8
|
|
21
|
1
|
|
|
1
|
|
259
|
use aliased 'Bio::MUST::Core::Seq'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
5
|
|
22
|
1
|
|
|
1
|
|
191
|
use aliased 'Bio::MUST::Core::SeqId'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
4
|
|
23
|
1
|
|
|
1
|
|
180
|
use aliased 'Bio::MUST::Core::SeqMask'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
3
|
|
24
|
1
|
|
|
1
|
|
180
|
use aliased 'Bio::MUST::Drivers::Blast::Database::Temporary'; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
3
|
|
25
|
1
|
|
|
1
|
|
207
|
use aliased 'Bio::MUST::Drivers::Mafft'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
5
|
|
26
|
1
|
|
|
1
|
|
210
|
use aliased 'Bio::MUST::Drivers::ClustalO'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
4
|
|
27
|
1
|
|
|
1
|
|
184
|
use aliased 'Bio::MUST::Apps::SlaveAligner::Local'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
4
|
|
28
|
1
|
|
|
1
|
|
173
|
use aliased 'Bio::MUST::Core::IdList'; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
3
|
|
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
has 'file1' => ( |
32
|
|
|
|
|
|
|
is => 'ro', |
33
|
|
|
|
|
|
|
isa => 'Bio::MUST::Core::Ali', |
34
|
|
|
|
|
|
|
required => 1, |
35
|
|
|
|
|
|
|
coerce => 1, |
36
|
|
|
|
|
|
|
); |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
has 'file2' => ( |
39
|
|
|
|
|
|
|
is => 'ro', |
40
|
|
|
|
|
|
|
isa => 'Bio::MUST::Core::Ali', |
41
|
|
|
|
|
|
|
required => 1, |
42
|
|
|
|
|
|
|
coerce => 1, |
43
|
|
|
|
|
|
|
); |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
has 'ali' => ( |
46
|
|
|
|
|
|
|
is => 'ro', |
47
|
|
|
|
|
|
|
isa => 'Bio::MUST::Core::Ali', |
48
|
|
|
|
|
|
|
init_arg => undef, |
49
|
|
|
|
|
|
|
writer => '_set_ali', |
50
|
|
|
|
|
|
|
handles => qr{.*}xms, |
51
|
|
|
|
|
|
|
); |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
has 'options' => ( |
54
|
|
|
|
|
|
|
traits => ['Hash'], |
55
|
|
|
|
|
|
|
is => 'ro', |
56
|
|
|
|
|
|
|
isa => 'HashRef', |
57
|
|
|
|
|
|
|
default => sub { {} }, |
58
|
|
|
|
|
|
|
); |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
sub BUILD { |
62
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
63
|
|
|
|
|
|
|
|
64
|
0
|
|
|
|
|
|
my $ali1 = $self->file1; |
65
|
0
|
|
|
|
|
|
my $ali2 = $self->file2; |
66
|
0
|
|
|
|
|
|
my $opt = $self->options; |
67
|
|
|
|
|
|
|
|
68
|
0
|
|
|
|
|
|
my ($filename1, $id_mapper1) = $ali1->temp_fasta( {id_prefix => 'file1-'} ); |
69
|
0
|
|
|
|
|
|
my ($filename2, $id_mapper2) = $ali2->temp_fasta( {id_prefix => 'file2-'} ); |
70
|
|
|
|
|
|
|
|
71
|
0
|
|
|
|
|
|
my %mapper = ( ali1 => $id_mapper1, ali2 => $id_mapper2 ); |
72
|
|
|
|
|
|
|
|
73
|
0
|
|
|
|
|
|
my $mafft = Mafft->new( file => $filename1 ); # add an option to use clustalo if wanted ? |
74
|
0
|
|
|
|
|
|
my $ali_out = $mafft->seqs2profile($filename2, $opt); |
75
|
|
|
|
|
|
|
|
76
|
0
|
|
|
|
|
|
$ali_out->restore_ids($mapper{ali1}); |
77
|
0
|
|
|
|
|
|
$ali_out->restore_ids($mapper{ali2}); |
78
|
|
|
|
|
|
|
|
79
|
0
|
|
|
|
|
|
$self->_set_ali($ali_out); |
80
|
|
|
|
|
|
|
|
81
|
0
|
|
|
|
|
|
return; |
82
|
|
|
|
|
|
|
} |
83
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
84
|
|
|
|
|
|
|
1; |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
__END__ |
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
=pod |
89
|
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
=head1 NAME |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
Bio::MUST::Apps::TwoScalp::Seqs2Profile - internal class for two-scalp tool |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
=head1 VERSION |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
version 0.231010 |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
=head1 SYNOPSIS |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
# TODO |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
=head1 DESCRIPTION |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
# TODO |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
=head1 AUTHOR |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
Denis BAURAIN <denis.baurain@uliege.be> |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
=head1 CONTRIBUTORS |
111
|
|
|
|
|
|
|
|
112
|
|
|
|
|
|
|
=for stopwords Amandine BERTRAND Valerian LUPO |
113
|
|
|
|
|
|
|
|
114
|
|
|
|
|
|
|
=over 4 |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
=item * |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
Amandine BERTRAND <amandine.bertrand@doct.uliege.be> |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
=item * |
121
|
|
|
|
|
|
|
|
122
|
|
|
|
|
|
|
Valerian LUPO <valerian.lupo@doct.uliege.be> |
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
=back |
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
This software is copyright (c) 2013 by University of Liege / Unit of Eukaryotic Phylogenomics / Denis BAURAIN. |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
131
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
132
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
=cut |