Improve Statistics results for some special NLFit types

Version: 2019b

Type: Features

Category: Analysis

Subcategory: Fitting

Jira: ORG-19777

For Nonlinear Multiple Dependent Variables Fitting, ANOVA table is improved.

Before 2019b, ANOVA table in the report only shows the results for the first dataset(Dataset B in the following case). Now the result is improved and similar to Global Fit's result, DF and TSS should be total data.

For the Nonlinear Fitting using Orthogonal Distance Regression, R-Square quantity is improved.

Before 2019b, R-Squared value may always be 1 though the ODR fit is normal. It is caused by the inappropriate TSS. Now the R-Square should be more accurate as TSS calculation is improved as:

TSS = sum( (y - ymean)^2) + sum( (x - xmean)^2)
R^2 = 1 - RSS/TSS
where TSS is the total sum of square, and RSS is the residual sum of square.