R Programming: Selection of variables