limit historic results based on $history parameter