1, in statistics, the calculation method of r square value is as follows:
R squared value = regression sum of squares (ssreg)/ total sum of squares (sstotal)
Where sum of regression squares = sum of total squares-sum of residual squares (ssresid)
2. The above terms are explained as follows:
Total sum of squares: when Const parameter is true, total sum of squares = sum of square difference between actual value and average value of Y; When Const parameter is False, total sum of squares = sum of squares of actual value of y.
Sum of squares of residuals: sum of squares of residuals = sum of squares of the difference between the estimated value of y and the actual value of y.
3. In linear regression analysis, RSQ function can be used to calculate R-squared value.
The syntax of RSQ function is RSQ (Y-known, X-known).
By substituting the Y-axis data and X-axis data in the source data respectively, the R-squared value of its "linear" trend line can be obtained.
Characteristics of 4, r 2:
(1) The determinable coefficient is a nonnegative statistic.
(2) The range of determinable coefficient: 0
(3) The determinable coefficient is a function of the observed values of the samples, and the determinable coefficient R 2 is a random variable with random sampling changes. Therefore, the statistical reliability of determinable coefficients should also be tested.