R Package for the Groovy Scripting Language

BitBucket | CRAN | Advanced Example

This package integrates the Groovy Scripting Language with the R Project for Statistical Computing allowing users to mix Groovy script with R script. This can be particularly helpful when, for example, a Java framework needs to be augmented with only a few lines of code in order to complete the solution for a given problem — in this example the user can write some code in Groovy and not have to spend time with a Java compiler and shipping class files.

From groovy.codehaus.org: Groovy…

  • is an agile and dynamic language for the Java Virtual Machine
  • builds upon the strengths of Java but has additional power features inspired by languages like Python, Ruby and Smalltalk
  • makes modern programming features available to Java developers with almost-zero learning curve
  • provides the ability to statically type check and statically compile your code for robustness and performance
  • supports Domain-Specific Languages and other compact syntax so your code becomes easy to read and maintain
  • makes writing shell and build scripts easy with its powerful processing primitives, OO abilities and an Ant DSL
  • increases developer productivity by reducing scaffolding code when developing web, GUI, database or console applications
  • simplifies testing by supporting unit testing and mocking out-of-the-box
  • seamlessly integrates with all existing Java classes and libraries
  • compiles straight to Java bytecode so you can use it anywhere you can use Java

Using Grape can super-charge your R script by tying into Maven directly thereby removing entirely the need to ship jar files with your R script.

Technical Requirements

  • Java 1.7+
  • R version 3.0.3+

License

The R Package for the Groovy Scripting Language (rGroovy) is available under the open source LGPL license.

See Also

Leave a Reply

Your email address will not be published. Required fields are marked *