added data collapsing