構造体の関数を別の関数内で使うには
Afficher commentaires plus anciens
アプリ「回帰学習器」で作成したガウス過程回帰モデルを構造体としてワークスペースにエクスポートしました。
その構造体を別の関数内で使いたいと考えているのですが、以下のようになり上手くいきません。
・A_xnew: 1×11のtable
・A_ini_ind: ワークスペース内の50×11のtable
・A_trainedModel: アプリで作成した構造体
----------------------------------------------------------------------------------------------------------------------
function t = A(A_xnew)
t = min(A_trainedModel.predictFcn(A_ini_ind)) - A_trainedModel.predictFcn(A_xnew)
end
----------------------------------------------------------------------------------------------------------------------
以上を関数A(A_xnew)として実行すると、"名前 A_trainedModel.predictFcn を解決できません。"と出力されます。
私自身の知識不足であることは承知なのですが、解決する方法をご回答いただけると嬉しいです。
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur ワークスペース変数と MAT ファイル dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!