Using the fitlm function for model without intercept, how R-squared is being calculated?

7 次查看(过去 30 天)
The value of the R-squared when I define the linear model without intercept are mostly negative and somehow close to -3. When I apply the fitlm function for model without intercept, the R-squared values are between 0 and 1. Does anyone know which formula Matlab is using in this case?
  1 个评论
Shuqi Liu
Shuqi Liu 2021-7-19
Also when using fitlm without intercept, the Rsquared comptued by fitlm is different using Matlab 2020a and prior vs 2020b. Does anyone knows why did it change?

请先登录,再进行评论。

回答(1 个)

Rishabh Gupta
Rishabh Gupta 2018-7-27
Hi Farhad,
There are 2 types of R-squared values -
  1. Ordinary R-Squared
  2. Adjusted R-Squared
You can have a look at the formula in the below Link:
Regards

类别

Help CenterFile Exchange 中查找有关 Dimensionality Reduction and Feature Extraction 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by