fit function - Incorrect number or types of inputs or outputs for function fit.

I'm trying to fit data into a function, and it was failing. So to understand it, it've tried the matlab example, and it give me the same error:
Incorrect number or types of inputs or outputs for function fit.
So i'm a bit lost because even the example is failing...

2 Kommentare

Please show us the output of this command:
which fit -all
/MATLAB/toolbox/curvefit/curvefit/fit.m /MATLAB/toolbox/mbc/mbcdesign/@contwostage/fit.m % contwostage method /MATLAB/toolbox/mbc/mbcdesign/@conbase/fit.m % conbase method /MATLAB/toolbox/mbc/mbcdesign/@conswitch/fit.m % conswitch method /MATLAB/toolbox/mbc/mbcmodels/@localmod/fit.m % localmod method /MATLAB/toolbox/mbc/mbcmodels/@localmulti/fit.m % localmulti method /MATLAB/toolbox/mbc/mbcmodels/@xregmodel/fit.m % xregmodel method /MATLAB/toolbox/stats/stats/@gmdistribution/fit.m % gmdistribution method
Also: tell us what MATLAB version you are using, and whether you have a license for the Curve Fitting Toolbox.
Hi Stephen, thanks for answering first.So here's what i got from the cmd. For the Curve Fitting Toolbox, i've asked for a trial last week, so i expect it to be fine. I'm on 2024b.

Melden Sie sich an, um zu kommentieren.

 Akzeptierte Antwort

Stephen23
Stephen23 am 2 Mär. 2026
Verschoben: Steven Lord am 2 Mär. 2026
@Kevin: you do not have FIT from the Curve Fitting Toolbox listed. Check your licenses online:

1 Kommentar

Kevin
Kevin am 2 Mär. 2026
Verschoben: Steven Lord am 2 Mär. 2026
Hi Stephen, thanks for noticing. I must had made a mistake as i thought i downloaded it. Thanks, and sorry for the disturbance.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Startup and Shutdown finden Sie in Hilfe-Center und File Exchange

Produkte

Version

R2024b

Gefragt:

am 2 Mär. 2026

Verschoben:

am 2 Mär. 2026

Community Treasure Hunt

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

Start Hunting!

Translated by