correct handling of newly created variable in summarise. closes #259