Sorts transaction history and creates aligned balance sheets