Added collate function. Improved table visualization.