We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 784eeec commit 9033c8eCopy full SHA for 9033c8e
SAM_entry.pm
@@ -148,6 +148,25 @@ sub get_genome_span {
148
return($min_coord, $max_coord);
149
}
150
151
+####
152
+sub get_read_span {
153
+ my $self = shift;
154
+
155
+ my ($genome_aref, $read_aref) = $self->get_alignment_coords();
156
157
+ my @coords;
158
+ foreach my $read_coordset (@$read_aref) {
159
+ push (@coords, @$read_coordset);
160
+ }
161
162
+ @coords = sort {$a<=>$b} @coords;
163
164
+ my $min_coord = shift @coords;
165
+ my $max_coord = pop @coords;
166
167
+ return($min_coord, $max_coord);
168
169
+}
170
171
####
172
sub get_alignment_length {
0 commit comments