Quantitative analysis of adaptiveness and consistency of a class of online learning algorithms