juliaCall | R Documentation |
Call a Julia function via specifying the name as string and get the translated result. It is also possible to use a dot at the end of the function name for applying the function in a vectorized manner via "broadcasting" in Julia.
juliaCall(...)
... |
the name of the Julia function as first argument, followed by the parameters handed to the function. All arguments to the Julia function are translated to Julia data structures. |
The value returned from Julia, translated to an R data structure.
If Julia returns nothing
, an invisible NULL
is returned.
if (juliaSetupOk()) {
juliaCall("/", 4, 2)
juliaCall("Base.div", 4, 2)
juliaCall("sin.", c(1,2,3))
juliaCall("Base.cos.", c(1,2,3))
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.