Gordon Anderson wrote:
I have a couple Qns about boost accumulators in 1_37_0 -
1) Central moments ? -
There are accumulators for simple kth moments - boost/accumulators/statistics/moment.hpp
Are central kth moments [relative to the mean] there somewhere?
Obviously you can construct one from the other with a weighted sum of the k moments on the same data.
I don't think it's there yet. I'm cc'ing Matthias in case he has some kth moment accumulators lying around somewhere. If not, I'd be happy to accept patches.
2) Slow build ! -
It is a bit slow to compile code using eg. moment<6> accumulators.. It takes around 12 seconds on my machine to build sample code with 'moment<12>'
exponential recursive template evaluation??
I'm using gcc 4.2.4
There shouldn't be any dependence of compile time on the "N" in moment<N>. Are you seeing that? I've experienced long compile times with accumulators, too. It certainly has never been optimized for compile times, and there's probably a lot of room for improvement here. I unfortunately don't have time to look into. The emphasis with accumulators has always been to make runtime as efficient as possible, FWIW. -- Eric Niebler BoostPro Computing http://www.boostpro.com