Collect Statistics efficiently and easily

Brett Brett at
Tue Sep 17 01:53:39 UTC 2019

Many times I have to get statistical info which is simply compute 
statistics on a data set that may be generating or already 

The code usually is

M = max(M, v);
m = min(m, v);

but other things like standard deviation, mean, etc might need to 
be computed.

This may need to be done on several data sets simultaneously.

is there any way that one could just compute them in one line 
that is efficient, probably using ranges? I'd like to avoid 
having to loop through a data set multiple times as it would be 
quite inefficient.

More information about the Digitalmars-d-learn mailing list