Blog Archives

Blog with Knitr and Jekyll

July 3, 2012
By
Blog with Knitr and Jekyll

The knitr package provides an easy way to embed R code in a Jekyll-Bootstrap blog post. The only required input is an R Markdown source file. The name of the source file used to generate this post is 2012-07-03-knitr-jekyll.Rmd, available here. Steps taken to build this post are as follows:Step 1Create a Jekyll-Boostrap blog if...

Read more »

Grid2Polygons

June 25, 2012
By
Grid2Polygons

I’d like to introduce you to the Grid2Polygons function; an R function for converting sp spatial objects from class SpatialGridDataFrame to SpatialPolygonsDataFrame. The significance of this conversion is that spatial polygons can be transformed to a different projection or datum with the spTransform function in package rgdal. Postscript files created with spatial polygons are reduced in size and...

Read more »

Grid2Polygons

June 4, 2012
By
Grid2Polygons

I’d like to introduce you to the Grid2Polygons function; an R function for converting sp spatial objects from class SpatialGridDataFrame to SpatialPolygonsDataFrame. The significance of this conversion is that spatial polygons can be transformed ...

Read more »

Color Tools

June 1, 2012
By
Color Tools

Colors are mysterious business and choosing the right color or color palette for an R graphics can sometimes be a chore. To alleviate this burden, I present two functions for choosing color values.To access these functions install the RSurvey and dichromat packages: install.packages(c("RSurvey", "dichromat")) library(RSurvey)Choose ColorThe first function, ChooseColor (source), calls upon a graphical user interface (GUI)...

Read more »