fitnlm interpretation of results

6 ビュー (過去 30 日間)
Pooneh Shah Malekpoor
Pooneh Shah Malekpoor 2023 年 10 月 25 日
回答済み: Avadhoot 2023 年 10 月 30 日
Hi everyone
I have fitted a regression curve to my data using weighted least square method by fitnlm. The question is :
According to the properties below, how can I realize if the results from fitnlm are reasonable? The R-Squared and Coefficients are as attached below. The result of my fit is also shown below.
Thanks
Pooneh

回答 (1 件)

Avadhoot
Avadhoot 2023 年 10 月 30 日
Hi Pooneh,
I understand that you have fitted a non-linear model to your data, and you want to analyse the goodness of fit for the model using its parameters.
As you have used a non-linear model, the residual equation,
SST = SSR + SSE
does not hold true. As a result of that the value of R2 comes out to be negative. Hence R2 cannot be used as a metric for measuring goodness of fit. You can use the values of MSE and RMSE to get an idea of the variance of the error. But it is useful only if the error term is Gaussian in nature.
Other parameters like tStat,pValueand SE indicate that the model is poorly fitting the data as the "pValue" is very low and "tStat" and "SE" are high.
Lastly, you can use the plot of actual vs predicted values to understand if the fit is optimal or not. From the plot it can be seen that the model is a poor fir for the data.
You can refer to the following documentation for more information about non-linear models and goodness of fit:
  1. Nonlinear regression model - MATLAB - MathWorks India
  2. Evaluating Goodness of Fit - MATLAB & Simulink - MathWorks India
I hope it helps.

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by