Can I use tic and toc inside a parfor?

Hello there,
I was wondering if I could do something like:
my_times = zeros(1,N);
parfor past_image = 1:N
my_time = tic;
do_stuff;
my_times(past_image) = toc(my_time);
end
Thanks,
Pedro

More Answers (0)

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Products

Asked:

on 16 Dec 2014

Commented:

on 16 Dec 2014

Community Treasure Hunt

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

Start Hunting!