[
https://issues.apache.org/jira/browse/MATH-1494?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16911228#comment-16911228
]
Gilles commented on MATH-1494:
------------------------------
Thanks for your interest in contributing.
There are however several issues with the
[PR|https://github.com/apache/commons-math/pull/112]:
* the unit test file is missing a license header (hence the [Travis
failure|https://travis-ci.org/apache/commons-math/builds/574043415?utm_source=github_status&utm_medium=notification]),
* the code is missing Javadoc (everything, including {{private}} fields and
methods, must commented; see other files in the library)
* non-trivial functionality should be commented with code comments (for future
maintenance),
* source must follow a common code style (e.g. no "_" in identifiers).
* instantiation of exceptions, e.g.:
{code:java}
throw new DimensionMismatchException(new DummyLocalizable("Array lengths must
be equal"), x.length, y.length);
{code}
should rather just be
{code:java}
throw new DimensionMismatchException(x.length, y.length);
{code}
In general, prior to open of PR, you should run
{noformat}
$ mvn clean site
{noformat}
Then, web pages are generated (in the "target/site" directory), and a "Project
Reports" link will list many issues that can potentially prevent merging into
the "master" branch (look especially at the "CheckStyle" and "FindBugs"
reports).
About unit tests:
* there should be one test method per tested functionality, e.g.:
{{testEvaluate()}}, {{testEvaluateUnsorted()}},
{{testEvaluateUnsortedArray()}}, and so on,
* exceptions (e.g. preconditions) should be tested too (see other files).
All these can be easily fixed; however, as I indicated previously, your
proposed contribution does not fit within the current design of the
{{o.a.c.m.fitting}} package.
The radically different approach to estimate the parameters makes it unsuitable
to simply drop it there. [Design
decisions|http://www.apache.org/foundation/governance/pmcs.html#communication]
must happen on the ["dev" ML|http://commons.apache.org/mail-lists.html]; so a
discussion _must_ be started there.
Does a reference paper exist in English?
> Find exponential curve fit to data using Jacquelin method
> ---------------------------------------------------------
>
> Key: MATH-1494
> URL: https://issues.apache.org/jira/browse/MATH-1494
> Project: Commons Math
> Issue Type: New Feature
> Reporter: Tom Prodehl
> Priority: Major
> Labels: curvefitter, exponential, fitting
> Fix For: 4.0
>
> Original Estimate: 336h
> Time Spent: 10m
> Remaining Estimate: 335h 50m
>
> Function to fit an exponential decay (negarive beta) or positive beta without
> initial guessing
> Based on [https://stackoverflow.com/a/39436209/545346]
> Original source: Regressions et Equations integrales, Jean Jacquelin
> [https://www.scribd.com/doc/14674814/Regressions-et-equations-integrales]
> The class will allow for the usual variety of providing inputs of x and y.
> Once computed the instance can be queried for Amplitude, Beta, and Constant,
> defining a curve for y= Amplitude * exp(Beta * x) + Constant
--
This message was sent by Atlassian Jira
(v8.3.2#803003)