With a series of announcements made for R inclusion in
Hadoop distribution and relational database software packages, suddenly R is
becoming the flavor of predictive analytics. It’s time to preview R offerings
for Hadoop world and where the things seemed to be heading.
Hadoop distribution with R
R was developed around 1993 by Ross Ihaka, Robert Gentleman
as a statistical computing language and environment. Open sourced in 1996, the
free software is available under GNU licence from r-project.org/CRAN (Comprehensive
R Archive Network) servers. Most of the commercial Hadoop distributions today
have a R package inclusion or have similar plans. Cloudera and Hortonworks have
recently announced partnership with Revolution Analytics, a popular vendor
offering enterprise edition. IBM has been offering R as statistical analysis
package as part of Infosphere BigInsights for couple of years now. Also, IBM
Netezza/Pure Data hardware systems offer R package as a software inclusion. While
IBM SPSS is more of a bete noir of R, it also offers R integration. SAS, not a
Hadoop focused company, but a prominent player in predictive analytics also
offers R integration. Intel which ventured into Hadoop distributions also has
recently announced a partnership with Revolution Analytics. MapR, another
leading Hadoop distribution company has a partnership with Revelytix which
offers Loom software with R integration. Greenplum/Pivotal also offer R
integration as part of its database and Hadoop offering.
R on Hadoop integration hacks
Among the non Hadoop distribution options, RHIPE (pronounced
hree-pay') is the R and Hadoop Integrated Programming Environment. RHive is
another tool from a Korean company(NexR) which offers a way to integrate R with Hive
for querying HDFS. Oracle among the big players offers it own distribution of R
software. Further, it provides a connector for integrating R and Hadoop. Amazon EMR also offers you an option of running R programs now. If you
are adventurous yourself and would like to hack your own R with Hadoop nodes
you could either copy libraries to each node or use a JDBC connection approach
from R with Hive or HBase. With SQL on Hadoop tools offering JDBC support,
hadoopsphere.com believes there will be more than a likely chance of
integrating R with Cloudera Impala, Apache Tez, IBM BigSQL and the likes in
future.
The following extract from a Google paper lists down one of
the approach to use R with MapReduce.
1.First, the user's
code calls google.apply() with a list of inputs and a provided function, FUN.
An archive is dynamically created on the client including R and all of the
needed libraries and then staged to the cluster management system in a
datacenter with available resources. FUN and its environment are serialized
and written out to a Bigtable in that datacenter.
2.Second, workers
tasks are spawned using the dynamically generated virtual machines providing
access to all of the R packages that were loaded in the calling instance's R session. These workers read in
the serialized environment from the Bigtable, execute the provided function
over a unique element of the input list, and write out the serialized results
to a different column of the Bigtable.
3.Third, and finally, the calling R instance reads back in the serialized return values from
each worker task, performs the necessary error handling, and returns the
computed list to the google.apply() caller
|
R on an unprecedented journey
It is no secret that the predictive modeling market is going
to get hotter and hotter in the days to come. Inclusion of R in technology
stacks offers one of the convenient ways of doing ensemble modeling. The amount
of buzz suddenly around R is unprecedented in its lifetime. While there are a
good number of folks having basic education on R, inclusion of another language
in stacks is bound to complicate the skilled resource requirement. The
commercial stack for R has been progressing rapidly but the open source
counterpart has not benefited much from this pace. For instance, the open source R continues to rely on in-memory, single threaded model. There are limited enterprise R options and dependence on one particular
commercial vendor leads to fears of vendor lock-in besides the fear of vendor
acquisition considering its size and history. However, with ex-SPSS and ex-SAS
folks forming the top management in Revolution Analytics, there is lesser doubt
that R’s enterprise show is being run by experienced hands. Price point still
remains one of the main winners for R vis-à-vis SPSS and SAS. We would not be
surprised if more commercial vendors for R crop up which would be a good thing
rather than a bad thing as long as the open source version continues to benefit
from the commercial run.
Thank you!
ReplyDelete