Flexibly reshape data.