How do I hold a subset of parameters constant in NLINFIT within Statistics Toolbox 5.9 (R2006b)?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have several parameters to fit using NLINFIT. However, sometimes I would like to fix a subset of the parameters to user-specified values.
Akzeptierte Antwort
MathWorks Support Team
am 27 Jun. 2009
An example showing how to fix a subset of parameters using NLINFIT follows:
1. Please download the file 'nlinfitsome.m' to your work directory.
2. Following is an example illustrating the use of NLINFITSOME:
load reaction
betafit = nlinfit(reactants,rate,@hougen,beta)
betafit1 = nlinfitsome([true false false true false],reactants,rate,@hougen,beta)
Notice that parameters 1 and 4 of 'betafit1' are fixed, as shown by comparing the initial parameters beta with betafit1:
betafit1 =
1.0000 0.0509 0.0297 0.1000 1.5519
>> beta
beta =
1.0000
0.0500
0.0200
0.1000
2.0000
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Get Started with Curve Fitting Toolbox finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!