IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
progress_show.m
Go to the documentation of this file.
1 %> @ingroup globals usercomm
2 %> @file
3 %> @brief Shows progress bars
4 
5 function progress_show()
7 global PROGRESS;
8 
9 
10 
11 for ib = 1:numel(PROGRESS.bars)
12  bar = PROGRESS.bars(ib);
13 
14  ela = toc(bar.tic);
15 
16  if isempty(bar.perc)
17  perccalc = bar.i/(bar.n+realmin);
18  else
19  perccalc = bar.perc;
20  end;
21 
22  proje = ela/perccalc;
23 
24  irverbose(['[', ((linspace(0, 1, 25) > perccalc)*3+43), ']', sprintf('%6.0fs/%6.0fs - %6.2f%% %s', ela, ...
25  iif(proje < Inf, sprintf('%6.0f', proje), ' ?'), perccalc*100, bar.title)], 3);
26 
27 end;
function irverbose(in s, in level)
function progress_assert()
function progress_show()
function iif(in cond, in x1, in x2)