フィルターのクリア

how to know how much time it takes to run the matlab code?

2 ビュー (過去 30 日間)
bsd
bsd 2011 年 7 月 22 日
Dear sir/madam,
I need to know, how much time does a code take to run and display the output? how can I calculate this in matlab? Looking forward to hearing from you soon.
Thanking you, BSD

採用された回答

Fangjun Jiang
Fangjun Jiang 2011 年 7 月 22 日
tic;
% do stuff
toc;
Also, see cputime(), etime(), clock()
  1 件のコメント
Jan
Jan 2011 年 7 月 23 日
And PROFILE. Be aware that CPUTIME can lead to unexpected results if you run a multi-core machine. And CLOCK suffers from its connection to the real time clock: Changing the day-light-saving time or an automatic update of the clock via NTP can disturb the speed measurements.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeClocks and Timers についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by