R and GIS – working with shapefiles

R has some very useful libraries for working with spatial data. In this blog we will look at some of the libraries and demonstrate few basic functionalities. Lets start with reading a shapefile. How to read a shapefile : We will use the maptools package to read the shape file. Along with the maptools package, … Read more

Categories R

Running R from Eclipse – StatET Features

In The previous blog we looked at how to install the StatET plugin that can be used to run R from eclipse. In This tutorial we will look at the various features of the plugin. Creating a New R Project or File. The plugin provides the following options We create a new R Project and … Read more

Categories R

Running R from Eclipse – StatET installation and Usage

Many developers, especially the Java developers are quite comfortable using eclipse for development. There is a very useful and powerful plugin called StatET that can enable eclipse to work as in IDE for R. Lets first look at how to install it on Linux(Ubuntu). The plugin is available from the eclipse marketplace. The eclipse update … Read more

Categories R

rapply function – explanation and examples

In this post we will look at one of the powerful ‘apply’ group of functions in R – rapply. rapply stands for recursive apply, and as the name suggests it is used to apply a function to all elements of a list recursively. We begin by first creating a straightforward list we use the rapply … Read more

Categories R

R – Turorial II

  NOTE : This tutorial has been superseded by the exhaustive tutorials Here Lists Collection of Objects of same or mixed type.List may also contain vector or other lists. Create a list using the funtion list(). The following example shows operations that can be performed on a list. > alphabets=list(a=”apple”,b=”ball”,c=”cat”) > alphabets $a [1] “apple” $b … Read more

R – Tutorial I

NOTE : This tutorial has been superseded by the exhaustive R tutorials Here Basics Start R in Windows using the program menu. To quit :  q(). to call help for a function. help([function]) or ?[function]. use double quotes to escape special characters and tokens. e.g. ?”for”. objects() or ls() to obtain list of objects stored. rm([object]) … Read more

R and Java – JRI Using Netbeans

Setting up R-Java in Netbeans is pretty straight forward. For those who need a walkthough here are the steps. Download and install R (for this example version 2.12.2). install rJava package.   Download and install Netbeans.  In Netbeans Create a new java project. we will call it RJava.  From the [R_HOME]>/library/rJava/jri/examples folder, copy the file rtest.java … Read more

R and Java – JRI using eclipse on 64 bit machines

Update – Check out the new RJava Eclipse Plugin.The steps to install rjava on a 64 bit machine is not very different from installing it on a 32 bit machine. however, here are the exact steps. 1. Install 64 bit java.2. Install R 2.12.X3. Start R and install the rjava package using the package installer.4. … Read more

R and Java – JRI using eclipse.

Update – Check out the new RJava Eclipse Plugin.R is a powerful language for statistical computing and graphics. R has a strong community support and is finding new use in the corporate world. If R can be integrated with Java, it would provide a greap acceptance into new products. A library called rjava exists that helps … Read more