How to call a function m-file within another m-file

3 ビュー (過去 30 日間)
rick
rick 2011 年 9 月 30 日
How can I call a separate function m-file within a for-loop of another m-file? Both are saved in the same path.

採用された回答

Fangjun Jiang
Fangjun Jiang 2011 年 9 月 30 日
Just call that function. If you have a function called myfun defined in myfun.m, you can call it anywhere in another m file.
a=1;
for k=1:3
myfun;
end

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeAdding custom doc についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by