Chenged eval function for R interfacing