jython.assign: Assign and get variables in Python from R
Description
Functions that assign and get Python variables from R.
Usage
jython.assign( rJython, var.name, value ) jython.get( rJython, py.var )
Arguments
rJython
rJython interpreter as instantiated by function rJython
var.name
a character string containing a valid python variable name
value
an R object whose equivalent wants to be assigned to the variable in python
py.var
Name of a python variable
Value
Function jython.get returns a R version of the Python variable py.var.
Details
These functions can assign values to variables in Python as well as get their values back to R.
Objects are serialized as json strings while being transferred between R and Python.