File Exchange

image thumbnail


version 1.0.1 (1.88 KB) by Girmi Schouten
Waitbar implementation for parfor loops.


Updated 13 Dec 2019

View Version History

View License

This package provides a waitbar for use in parfor loops without the need to write to files or any other external synchronization.

Cite As

Girmi Schouten (2021). waitbarParfor (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (3)

Olaf Bousche

Great function.

To make it more useful I suggest a few small changes I made myself. I added the following code in the update function:
if toc(t_start) - t_last > 1
t_last = t_last + 1;
d = seconds(toc(t_start));
d.Format = "hh:mm:ss";
waitbar(loopCnt/totalLoops, waitbarHandle, compose("t = %s, %s",d,waitbarMessage));

And of course the corresponding start of the timer variable in the initialization:
% Get the time
t_start = tic;
t_last = 0;


Toon Stas


MATLAB Release Compatibility
Created with R2019b
Compatible with R2019b and later releases
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

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

Start Hunting!