tags 352454 upstream forwarded 352454 http://rt.cpan.org/Ticket/Display.html?id=17600 thanks
> while using libmath-numbercruncher-perl I found the following issue. > Feeding the results of 'BestFit' into 'Predict' results in a wrong answer, in > my case 'NAN'. Hi, this is an incompatibility between Math::NumberCruncher and current versions of Math::BigInt. It happens because BestFit() rounds its return values into a fixed precision, while Predict() calls Math::BigFloat::bmul() with a specific accuracy. Since version 1.49 Math::BigInt enforces that only one of these can be specified, and returns NaN if this is not the case. I have forwarded your report to the upstream bug tracking database at http://rt.cpan.org/Ticket/Display.html?id=17600 . I don't have a good fix, but a workaround is to explicitly reset the accuracy of the arguments of Predict(): my ($slope, $y_intercept) = Math::NumberCruncher::BestFit([EMAIL PROTECTED], [EMAIL PROTECTED]); $slope->accuracy(undef); $y_intercept->accuracy(undef); my $predicted_value = Math::NumberCruncher::Predict( $slope, $y_intercept, 4); Thank you for your report, -- Niko Tyni [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]