Branch Coverage

blib/lib/PDL/NDBin.pm
Criterion Covered Total %
branch 119 154 77.2


line true false branch
75 0 269 unless $axis_allowed{$pmask}
101 0 244 if $PDL::NDBin::log->is_debug
108 177 10 if (@$axis > 1)
124 1187 232 wantarray ? :
125 1133 462 wantarray ? :
139 109 89 substr($short_class, 0, 1) eq '+' ? :
152 37 161 if (ref $params{'action'} eq 'CODE') { }
4 157 elsif (ref $params{'action'} eq 'HASH') { }
180 308 280 if $v->{'name'} eq $name
190 416 76 if defined $v->{'pdl'}
191 76 0 if $v->{'action'} eq 'Count'
193 0 0 if $warned_for{$name}
206 232 260 unless defined $length
211 92 138 if $v->{'action'} and !defined($v->{'pdl'}) || $v->{'pdl'}->isempty
212 0 400 if ($v->{'pdl'}->nelem != $length)
225 157 23 if (defined $axis->{'step'} and defined $axis->{'min'} and defined $axis->{'n'})
230 0 105 unless defined $axis->{'pdl'}
232 1 104 if ($axis->{'pdl'}->isempty)
238 9 95 if (defined $axis->{'grid'})
242 0 9 if $axis->{'grid'}->nelem < 2 or $axis->{'grid'}->ndims > 1
251 73 22 unless defined $axis->{'min'}
254 73 22 unless defined $axis->{'max'}
255 2 93 if (defined $axis->{'round'} and $axis->{'round'} > 0)
259 0 95 if $axis->{'max'} < $axis->{'min'}
260 64 31 if ($axis->{'pdl'}->type >= PDL::float())
261 1 63 if $axis->{'min'} == $axis->{'max'}
267 31 63 if ($axis->{'pdl'}->type < PDL::float())
271 23 71 if (defined $axis->{'step'})
272 0 23 unless $axis->{'step'} > 0
273 0 23 if ($axis->{'pdl'}->type < PDL::float() and $axis->{'step'} < 1)
278 46 48 if (defined $axis->{'n'}) { }
279 0 46 unless $axis->{'n'} > 0
280 0 46 if ceil($axis->{'n'}) - $axis->{'n'} > 0
283 23 25 if (defined $axis->{'step'}) { }
294 4 21 $axis->{'pdl'}->nelem > 100 ? :
302 71 23 if (not defined $axis->{'step'})
305 23 48 if ($axis->{'pdl'}->type < PDL::float())
306 1 22 if $axis->{'step'} < 1
329 3 7 if (defined $axis->{'grid'}) { }
343 8 4 $step > 1 ? :
8 12 $pdl->type >= PDL::float() ? :
355 0 8 wantarray ? :
364 2 220 unless @{$self->axes;}
366 74 146 unless @{$self->vars;}
377 0 242 if ($PDL::NDBin::log->is_debug)
379 0 0 if (not defined $axis->{'grid'}) { }
386 1 241 unless $axis->{'n'} > 0
388 3 238 if (defined $axis->{'grid'}) { }
395 0 214 if $PDL::NDBin::log->is_debug
399 0 214 unless $N
424 0 187 unless defined wantarray
425 181 6 unless (defined $self->{'result'})
430 0 181 if ($PDL::NDBin::log->is_debug)
432 0 181 if ($PDL::NDBin::log->is_debug)
434 0 187 wantarray ? :
443 32 278 unless (&$f())
455 58 39 if (eval { do { $_[0]->isa('PDL') } }) { }
26 13 elsif (ref $_[0] eq 'HASH') { }
8 5 elsif (@num = &_consume(sub { /^[-+]?(\d+(\.\d*)?|\.\d+)([Ee][-+]?\d+)?$/; } , \@_)) { }
457 0 58 if $hash
463 0 26 unless $hash
468 0 8 unless $hash
469 1 7 if @num > 3
471 7 0 if @num > 0
472 7 0 if @num > 1
473 7 0 if @num > 2
489 26 20 if $hash
507 110 38 unless eval { do { $_->isa('PDL') } }
515 7 19 if (@leading)
520 0 19 if @invalid_keys
533 13 0 if (@$var == 2) { }
544 0 18 wantarray ? :
558 74 58 unless eval { do { $_->isa('PDL') } }
52 3 if (my(@leading) = &_consume(sub { not $valid_key{$_} unless eval { do { $_->isa('PDL') } }; } , \@_))
566 0 49 if @invalid_keys
579 16 0 if (@$var == 2) { }
589 0 42 wantarray ? :