While I can't really comment on how "reasonable" the approach is, I can certainly comment on the usefulness of it. I just put this together on my system; while learning to use Julia, it will be helpful to use this to blend the two languages until such time as I can make sole use of Julia for some tasks.
Chris On Tuesday, February 4, 2014 11:03:37 AM UTC-8, Douglas Bates wrote: > > Yihui Xie, the author of the knitr package for R, was kind enough to write > another R package https://github.com/yihui/runr that allows an author to > specify > > engine='julia' > > as a knitr chunk option. > > knitr allows for literate programming by processing a file in LaTeX or > Markdown with embedded chunks of code that are evaluated. Usually the > evaluation is of R code chunks but this option allows for Julia code to be > evaluated. > > knitr uses R to process the file, extracting code chunks according to > given patterns and causing them to be evaluated. For the julia engine a > julia process is initialized and set to receive messages over a socket, > evaluate the text passed to it and return the result over a socket. See > > https://github.com/yihui/runr/blob/master/inst/lang/julia_socket.jl > > I don't know a lot about ZMQ but I do know that there are bindings for ZMQ > in both Julia and in R. It seems to me that this would be a cleaner > mechanism for passing strings to a julia process, evaluating them, and > returning the result. > > Does this seem to be a reasonable approach? Are there other mechanisms I > should consider instead? > > >
