The context tree weighting method (CTW) is a lossless compression and prediction algorithm by . The CTW algorithm is among the very few such algorithms that offer both theoretical guarantees and good practical performance (see, e.g.).The CTW algorithm is an “ensemble method”, mixing the predictions of many underlying variable order Markov models, where each such model is constructed using zero-order conditional probability estimators.