To use EZfate to estimate particle dispersal from pre-computed particle tracks, you need to set up three things.

First, you must get this file:

This file can be retrieved from https://github.com/JamiePringle/EZfate/releases. This package also includes the R notebook pages that you are viewing now. They are all in the code directory.

Second: you need to decide upon a directory to store all the connectivity data. In all of the examples below, this is a directory called “connectivityData” that is kept in the same directory as the *.R and *.RMD files.

Third: You need the libraries given in the code block below.

To test the installation of these packages, run the code block below, and make sure it works. Don’t worry about the tidyverse conflicts.

library(ncdf4)
library(tidyverse)
library(sf)
library(collections)
library(iterators)
library(comprehenr,quietly=TRUE)
library(furrr) #optional, but highly recommend to allow parallel processing
library(doParallel) #optional, but highly recommend to allow parallel processing
library(foreach) #optional, but highly recommend to allow parallel processing
library(tictoc) #optional, only needed for debugging runs
library(rnaturalearth) #only needed for graphics 
library(rnaturalearthdata) #only needed for graphics
library(aws.s3) #for reading connectivity data from NSF's Open Storage Network

Several issues have come up for users when installing these packages. First, read any error messages that occur during installation. Often, especially on linux, they will suggest installing additional system libraries. Second, if you are using “conda” to manage python installations, make sure that you have no conda environments enabled. Having a conda environment installed when running R can lead to issues when installing these libraries. The errors arise from the operating system, R and python having different versions of libraries such as gdal and proj.

In the next section, you will learn how to get the connectivity data and subset it to your region of interest, and combine multiple connectivity data sets.