final version with sample compressing. a little work left for making sure that the dates are shown for samples