Moved reusable code to get_r_representation()
Moved reusable code to get_r_representation()

terrytangyuan/reticulate,terrytangyuan/reticulate,terrytangyuan/reticulate,rstudio/reticulate,rstudio/reticulate,rstudio/reticulate,rstudio/reticulate,rstudio/reticulate