functions: Function Versions of Methods for Python Interface evaluators.

Description Usage Arguments Functions

Description

These functions allow application code to invoke evaluator methods for essentially all basic computations. Usually, they access the current Python evaluator, starting one if none exists. For details, see the documentation for the corresponding method, under PythonInterface.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
pythonSend(object, evaluator = XR::getInterface(.PythonInterfaceClass))

pythonEval(expr, ..., evaluator = XR::getInterface(.PythonInterfaceClass))

pythonCommand(expr, ..., evaluator = XR::getInterface(.PythonInterfaceClass))

pythonCall(fun, ..., evaluator = XR::getInterface(.PythonInterfaceClass))

pythonGet(object, evaluator = XR::getInterface(.PythonInterfaceClass))

pythonSource(file, ..., evaluator = XR::getInterface(.PythonInterfaceClass))

pythonDefine(text, file, ...,
  evaluator = XR::getInterface(.PythonInterfaceClass))

pythonSerialize(object, file, append = FALSE,
  evaluator = XR::getInterface(.PythonInterfaceClass))

pythonUnserialize(file, all = FALSE,
  evaluator = XR::getInterface(.PythonInterfaceClass))

pythonName(object)

pythonShell(..., evaluator = XR::getInterface(.PythonInterfaceClass))

Arguments

object

For pythonSend(), an R object, to be sent to Python. For pythonGet(), pythonSerialize() and pythonNqme(), a proxy object for a Python object.

evaluator

The evaluator object to use. By default, and usually, the current evaluator is used, and one is started if none has been.

expr

A string for a Python expression or command, with C-style fields ("%s") to be substituted for the following arguments, if any.

...

For the evaluation functions: Objects, either R objects to be converted or proxies for Python objects previously computed. For other functions, specialized arguments for the corresponding method. In particular, .get= for controlling whether the computed result should be converted.

fun

the string name of the function; a module name must be included in the string if the function has not been explicitly imported from that module.

file

A filename or an open connection, for reading or writing depending on the function

text

the definition as text (supply argument file= instead to read it from a file)

append

should the serializing text be appended to a file; otherwise the file will be truncated on opening.

all

should the unserialized object be a list of all serialized objects on the file?

Functions


XRPython documentation built on May 2, 2019, 9:33 a.m.