Fit curve to a model problem
3 views (last 30 days)
Show older comments
Hi dear users,
I have a set of data in the graph below
And I'm trying to fit this data to a Magic formula tyre model which looks like this
Where D,C,B, and E are coefficients that I need to get from Matlab.
Now I've tried the fitting tool and inserting this custom model but I can never get it to fit even remotely good.
Anyone have any ideas?
0 Comments
Accepted Answer
the cyclist
on 3 Nov 2021
Personally, I would use fitnlm from the Statistics and Machine Learning Toolbox, but that is mainly due to familiarity, I suppose.
Could it be poor initial guesses for the parameters? For example, if you start with B > 0, I can imagine a fitting routine might struggle.
Can you upload the data here?
More Answers (1)
Sulaymon Eshkabilov
on 4 Nov 2021
There are a couple of other fit model fcns of the toolbox that can be employed with your exercise. They are nlinfit() and nlintool()
1 Comment
the cyclist
on 4 Nov 2021
I would strongly recommend fitnlm over using nlinfit directly. fitnlm calls nlinfit under the hood, but the resulting model object you get is much easier in general to work with for next steps.
See Also
Categories
Find more on Regression in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!