Posts Tagged ‘ R Spatial Data hints ’

Installing rgdal on Mac OS X

November 2, 2010
By
Installing rgdal on Mac OS X

After running a spatial data analysis with R session today, it became apparent that there are one or two teething problems installing the important rgdal package on Mac OS X operating systems. The usual install.packages(“rgdal”) won’t work. My colleague Jon Reades did some digging around to find this solution. I have tested it and it

Read more »

Maps with ggplot2

September 27, 2010
By
Maps with ggplot2

The ggplot2 package offers powerful tools to plot data in R. The plots are designed to comply with the “grammar of graphics” philosophy and can be produced to a publishable level relatively easily. For users wishing to create a good map without too much thought I would recommend this worksheet. For those without their own

Read more »

Clipping a Surface By a Polygon

September 8, 2010
By
Clipping a Surface By a Polygon

Background: A common function in standard GIS software enables users to create a raster surface and extract values or clip it based on a set of polygons. This may be used in cases where you want analysis to be constrained to within a town’s boundaries or a coastline. This tutorial will outline how to create

Read more »

Writing a Spatial Function: The Location Quotient

September 7, 2010
By
Writing a Spatial Function: The Location Quotient

Background: In some cases it is necessary to conduct the same analysis multiple times on either the same or different data. In such circumstances it is worth writing a function to simplify the code. In this example the location quotient provides a simple calculation easily written in to a function. The location quotient (LQ) is

Read more »

R Maps

September 6, 2010
By
R Maps

This is an updated version of my Making Maps with R tutorial. I think the code is lot simpler and it also includes some data for you to play around with. Background: Spatial data are becoming increasingly common, as are the tools available in R to process it. Of course one of the best ways

Read more »