def METHOD_NAME(data, block_size):
    chain_length = data.shape[1]
    n_blocks = int(np.floor(chain_length / float(block_size)))
    return data[:, 0 : n_blocks * block_size].reshape((-1, block_size)).mean(axis=1)