4. What the bar reports

Seven switches add information to the bar, each with the colour keywords of an element:
f90
call bar%initialize(prefix_string='march ', bracket_left_string='[', bracket_right_string=']', &
filled_char_string='#', empty_char_string='.', &
add_progress_percent=.true., progress_percent_color_fg='yellow', &
add_progress_count=.true., progress_count_color_fg='cyan', &
add_progress_speed=.true., progress_speed_color_fg='green', &
add_eta=.true., eta_color_fg='blue', &
add_scale_bar=.true., scale_bar_color_fg='blue', &
add_date_time=.true., date_time_color_fg='magenta', &
add_summary=.true., summary_color_fg='green', &
width=30, max_value=real(steps, R8P))While running:
$ march
[ 0.00 (min) (max) 50.00]
march [###############...............] 50% 25/50 ( nn.nn%/s) ETA hh:mm:ssAt the end:
$ march
[ 0.00 (min) (max) 50.00]
march [##############################] 100% 50/50 ( nn.nn%/s) ETA hh:mm:ss
[yyyy/mm/dd hh:mm:ss - yyyy/mm/dd hh:mm:ss]
[done in n.nn s, nn.nn/s]On the bar line, in this order:
add_progress_percent: the progress in percent, right after the suffix, always one space apart from it:50%,100%.add_progress_count: the current value andmax_value,25/50. With whole-number bounds the count is an integer, right-aligned to the width ofmax_value, so the line does not shift; otherwise it is a real in six characters.add_progress_speed: the speed, in percent per second. It is smoothed: an exponential moving average of the speed between two drawings, which weights the last one bysmoothing(0.3 by default, as tqdm does).smoothing=1gives the momentary speed,smoothing=0the average since the start.add_eta: the estimated time to the end,ETA hh:mm:ss: what is left of the range, over the smoothed speed. It is--:--:--until the speed is known, at the first drawing.
On their own lines:
add_scale_barprints, when the bar starts, a scale above it withmin_valueandmax_value. It needs a bar at least 22 characters wide, and shows the values in five characters:0.00,50.00,100.0,2000,2.5e7.add_date_timeprints, when the bar is complete, a line with the date and time of the start and of the end.add_summaryprints, when the bar is complete, how long the run took and its mean speed: per second in the units of the range withadd_progress_count, in percent per second without.
The speed, the ETA, the summary and the dates change from a run to the next: the outputs of this documentation show them as nn.nn, hh:mm:ss, n.nn s and yyyy/mm/dd hh:mm:ss.
What you learned
Percent, count, smoothed speed, ETA; scale, start and end time, summary. Reference: The bar object, Number formats.
Next: 5. Spinners and counters.