bioperl / bioperl-live-redmine

Legacy tickets migrated from the OBF Redmine issue tracker: http://redmine.open-bio.org
0 stars 0 forks source link

Fu and Li's D crashes when $n <=3 #126

Open cjfields opened 8 years ago

cjfields commented 8 years ago

Author Name: Jason Stajich (@hyphaltip) Original Redmine Issue: 3313, https://redmine.open-bio.org/issues/3313 Original Date: 2011-11-15 Original Assignee: Bioperl Guts


Bioperl version: 1.006 Here are two error messages when I’m using this module to calculate Fu & Li’s statistics: Illegal division by zero at (the Statistics.pm file) line 359 Illegal division by zero at (the Statistics.pm file) line 376 A further tracking down shows that the first error happens when $n (sample size in the ingroup) equals 1 or 2, and the second error happens when $n equals 3. This is not really a bug though. I would suggest either in the original code, do a checking before the calculation (and skip the current calculation when $n == 1, 2, or 3 - rather than let the whole program die), or add a few lines of notes in the CPAN page.

cjfields commented 8 years ago

Original Redmine Comment Author Name: Jason Stajich Original Date: 2011-11-15T03:43:37Z


Reported by Cheng-Ruei Lee cl134@duke.edu