Hi, I want a time delay of, say, 2minutes be introduced in between the execution of two statements. Can anyone suggest about how to achieve that....Any definite MATLAB functions available for that?
Ofcourse I have the idea of running an infinite loop for a calculated number of cycles to achieve that ...but I dont think that is an universal best way to do it and make the program 'computer-independent'.
Thanks.
Anubhav

 採用された回答

Image Analyst
Image Analyst 2012 年 3 月 28 日

3 投票

How about
pause(120.0);

その他の回答 (1 件)

Surama Biswas
Surama Biswas 2019 年 5 月 24 日

0 投票

Also you can evaluate how much time required to execute your function f, by using timeit(f) and then use pause or simply using pause(timeit(f)).

カテゴリ

ヘルプ センター および File Exchange で Loops and Conditional Statements についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by