Get function output and time from timit
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Sndn_Shr
il 20 Gen 2018
Commentato: Sndn_Shr
il 20 Gen 2018
I have functions I need to time, which returns a single output. All functions are in separate files. How do I get that returned output when using timeit?
So far I have used tic,toc. But want to use timeit from now on.
0 Commenti
Risposta accettata
Walter Roberson
il 20 Gen 2018
You cannot get the actual function output from timeit.
You can look in the File Exchange for the code for timeit and modify that code to suit your needs.
Remember that timeit runs the code a variable number of times.
3 Commenti
Walter Roberson
il 20 Gen 2018
Read the documentation. It clearly says that timeit runs the code several times and takes the median.
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Loops and Conditional Statements in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!