R script to import WorldClim datalayers in GRASS GIS

As I wrote before, you can download monthly climate data layers (rainfall, mean minimum and maximum temperature of the coldest and warmest month respectively) from WorldClim for current and future climate conditions. The latter can only be downloaded in generic grid (raster) format (.bil). Moreover, monthly data layers are compressed in one zip file.

I also posted a small R script that unzips the zip files with monthly data layers downloaded from WorldClim (.bil format) and imports it your current GRASS GIS Location and Mapset. It also corrects erroneous grid cell values as discussed in that post.

I updated the script, hopefully making it easier to use. Continue reading “R script to import WorldClim datalayers in GRASS GIS”


ESRI rasters in GRASS or QGIS

To exchange data one should preferably use a non-proprietary format, such as the ARC/INFO ASCII GRID or GeoTIFF. Unfortunately, it still happens that data is distributed in a proprietary binary format.

One of the most widely used ones is the binary ESRI ARC/INFO GRID. Of course if you have ArcView or ArcGIS you can use these to convert the ARC/INFO GRID to an ARC/INFO ASCII GRID. But what about the others?

Well, as it turns out, GDAL, which is used by GRASS GIS, QGIS and many other GIS software packages, can open the binary ESRI ARC/INFO grids also. All you have to know is where to find the actual raster file. Continue reading “ESRI rasters in GRASS or QGIS”

Sharing libraries in Zotero

A good reference management software can make the life of a researcher much easier. There are many different software available, including various free or open-source software applications. My favorite tool is Zotero, which is a Firefox extension for the collection, managing, citation and sharing of your research sources. It is very powerful and has become indispensable in my research work.

A very nice feature is the option to store your citations online and share them with others. Continue reading “Sharing libraries in Zotero”

Accessing your file system from within R

R includes some powerful yet easy to use functions that provide a direct interface to the computer’s file system. In the example below I use two of these functions (file.info and file.copy) to copy a random selection of the songs on my computer to my mp3 player, while making sure that the combined size of these files does not exceed 500MB. Continue reading “Accessing your file system from within R”

Build in functions in R

Almost everything in R is done through functions. Quick-R gives a very useful overview of commonly used numeric and character functions for creating or recoding variables.

And while you are at it, check out the rest of the website. It provides information about, and helps new users to quickly learn more about the R Interface, data input, data management, basic and advanced statistics and basic and advanced graphs in R. It aims at ‘experienced users of popular statistical packages such as SAS, SPSS, Stata, and Systat’, but it is also very useful for current R users.

Edit: I just came across this site, which offers a guide for novice and intermediate users of R in the form of a mind map. The mind map is arranged in eight sections, or main branches, arranged by task. Each branch covers a general set tasks, such as learning to use R, running R, working with data, statistical analysis or plotting data. It looks like a very handy information tool. It is quite heavy on your computer resources, but the author already mentioned he might split the mind map up to reduce memory consumption.