robustfitの​反復はどのような条件​の時に終了しますか?

robustfitの反復はどのような条件の時に終了しますか?

 Risposta accettata

Kazuya
Kazuya il 12 Nov 2018

0 voti

ヘルプページには明記されていないですね。
edit robustfit
で関数の中身を確認すると、実際の処理は statrobustfit.m で実行されていることが分かります。。
edit statrobustfit
で中身を見ると(R2018b では・・ですが)
% Perform iteratively re-weighted least squares to get coefficient estimates
D = sqrt(eps(class(X)));
iter = 0;
iterlim = 50;
wxrank = xrank; % rank of weighted version of x
while((iter==0) || any(abs(b-b0) > D*max(abs(b),abs(b0))))
が見つかりますが、、この while 文の条件がお探しの条件かと見ていますが、、どうでしょう?基本的には 計算結果 b が変化しなくなるまで、といった条件みたいですが、反復回数は 50 回までという条件も見られます。

2 Commenti

KK
KK il 12 Nov 2018
ありがとうございます。 2017aだとrobustfitの中身までしか見れなかったため、大変参考になりました。くわしくは2018bにアップデート後に確認してみようと思います。
Kazuya
Kazuya il 12 Nov 2018
オリジナルのロバスト回帰を実装するような課題ですか?
statrobustfit 関数は private 関数なので
edit statrobustfit
では、開けませんね。
robustfit.m 内で statrobustfit 関数が実行されている箇所にて右クリック、メニューの中から「"statrobustfit" を開く」を選んで開いてみてください。

Accedi per commentare.

Più risposte (0)

Categorie

Prodotti

Release

R2017a

Richiesto:

KK
il 12 Nov 2018

Commentato:

il 12 Nov 2018

Community Treasure Hunt

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

Start Hunting!