@Halbvoll and @MRB3855 thanks for the followup discussion.
@Halbvoll I had the same concern when I posted my answer. @MRB3855 the sigma in the AICc for Least Squares is not RMSE, which I was confused initially as well. After communicating with a developer who has better knowledge on the subject, I now can explain what is going on, as follows.
- Least Squares does not estimate sigma as a free parameter. So the number of parameters in a Least Squares is the same as number of regression coefficients.
- The Least Squares estimate of Sigma is RMSE, which is sqrt(SSE/DF), where DF = Number of Observations - Number of Coefficients. This Sigma is not a free parameter in the sense of statistical estimation.
- The AICc formula uses the likelihood, which is based on the normal density function with Sigma, whose MLE is sqrt(SSE/N). The first term in the following screenshot is the contribution from Sigma's MLE. In such sense, when computing AICc in this way, the number of parameters must count Sigma in addition to regression coefficients.
I was pointed to the following article to see the full proof and complete derivation. If you are interested, see all the derivations up to Eq 6.
https://www.sciencedirect.com/science/article/pii/S0893965917301623?ref=cra_js_challenge&fr=RR-1
H.T. Banks and M. L. Joyner, 2017, AIC under the framework of least squares estimation, Applied Mathematics Letters, Volume 74.
We will take care of the clarification in a future version of the documentation. Thanks again!