Discrepancy in functions between MATLAB versions
37 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Tyler Hill
le 3 Juin 2024
Réponse apportée : Steven Lord
le 3 Juin 2024
I am bouncing between two machines using R2021b and R2024a Respectively. In my code that I had built on the R2021 machine, I had used the function fit to acquire a fit object for experimental data. In moving to the R2024 machine, the fit function seems to have a different use and returns the fllowing error when I run the code:
Incorrect number or types of inputs or outputs for function fit.
I am looking for a redirection to a function that would work as the fit function would in R2021 but for R2024. Any help would be appreciated, thank you.
0 commentaires
Réponse acceptée
Steven Lord
le 3 Juin 2024
What does the following command show when run in each of the versions of MATLAB?
which -all fit
My guess is that you have Curve Fitting Toolbox installed in your installation of release R2021b but don't have it in your installation of release R2024a. To check, run this code in both installations:
ver curvefit
If it doesn't show that last line in release R2024a, install Curve Fitting Toolbox.
This assumes you weren't calling the fit method of a gmdistribution object (Gaussian mixture model) created with Statistics and Machine Learning Toolbox. If that's the case (if you created a gmdistribution and called fit on it) check if you have that toolbox.
ver stats
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Get Started with Curve Fitting Toolbox dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!