every works except R code