Smathermather's Weblog

Remote Sensing, GIS, Ecology, and Oddball Techniques

Quantitative analysis of gorilla movement and R-Stat (part 2)

Posted by smathermather on November 23, 2016

In my previous post, I did a bit of setup on the who and what for analyzing gorilla data. Now let’s move into R-Stat a little bit, specifically installation and configuration.

For R, we’ll install whatever package is the correct one for your machine, and then also install R-Studio. This gives us a nice development environment for R.

Screen shot of R-Studio

We’re going to leverage a few packages in our work. The first is the “sp” package. This gives us “CLasses and Methods for Spatial Data” in R:

install.packages("sp")

We’ll also “rgdal”. This package gives us “Bindings for the Geospatial Data Abstraction Library”. For our use case here, this allows us to read shapefiles, geotiffs, and other spatial data.

install.packages("rgdal")

We’ll use “rmarkdown” also. This allows us to build a markdown file (think HTML but much simpler) that includes our code in code blocks, and can be compiled to a document whether a web page, pdf, etc.. This encourages us to write code and document it in one place, and ultimately will allow us to build some really great reporting functionality while getting our analysis work done.

install.packages("rmarkdown")

Finally, we’ll need the adehabitatLT package for aiding in our analysis of animal movement and habitat use.

install.packages("adehabitatLT")

We can, of course install all this in one swell foop as follows:

install.packages("sp")
install.packages("rgdal")
install.packages("rmarkdown")
install.packages("adehabitatLT")

Now we have all the building blocks we need to start analyzing our data. Stick around for part 3.

2 Responses to “Quantitative analysis of gorilla movement and R-Stat (part 2)”

  1. […] previous posts here1 and here2, I discussed a (then future) trip to Rwanda to help with GIS and gorilla […]

  2. […] previous posts here1, here2, and here3 discussed a then and future trip to Rwanda to help with GIS and gorilla […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: