A workshop in modeling post-fire recovery and ecosystem resilience in fynbos systems.
The workshop will consist primarily of stepping through example code that explores the use of LANDSAT NDVI data in modeling post-fire recovery of fynbos. The materials for the course are all available in a Git Repository at https://github.com/adammwilson/postfire.
The repository is structured as follows:
- workflows:
- data: Datasets used in analyses
- output: Temporary output from analysis
- Open RStudio
File
->New Project
->Version Control
->GIT
- Repository URL [email protected]:adammwilson/postfire.git
- Choose a location on your harddisk to save the repository
Git is designed to archive (multi-author) changes in text-based content (especially code). It is completely decentralized, so when you clone
a copy of a repository, you have the complete content and history of the files. If you want to edit the code and later still be able to download updates, it's good practice to create a personal branch
in your local copy. You can do this as follows:
-
In RStudio, click on the
Git
tab in the upper right corner -
Select the little gear icon ->
Shell
. This will open a terminal window where you have access to all git commands that are not available in the GUI. -
in the Git command shell, type:
git checkout -b yourname
where
yourname
is a name for your new branch (e.g.adam
ortesting
) -
Now look for the branch selector menu on the right side in the Git tab. You should see your new branch selected. If you click it, you will also see the
master
branch.
After switching to your new branch, you can edit and save the scripts. When you want to update to a newer version of the code, you need to:
commit
your changespull
updates from the master (look for the green down arrow or rungit pull
in the shell)- If you've edited a script that has also been updated on the master, you many need to
merge
the documents
Please attempt to have the following software installed and functioning prior to the workshop:
- RStudio This includes an installation of R. Use of RStudio is not vital for the course, participants could use the GUI included with R or another interface (e.g. EMACS-ESS if desired. However, in class we'll be demonstrating the use of RStudio, so it will be most straightforward if you use that.
- R packages. These are installed either with a package manager or via the command line (e.g.
install.packages(raster)
). See for here for a list of packages that we'll be using. - GRASS. We'll be giving a brief introduction to this full featured open-source GIS in one section of the workshop. It isn't vital that you have it installed , but if you do, you'll be able to follow along. If you do, please also install the spGRASS6 R library.
- JAGS Program for analysis of Bayesian hierarchical models using Markov Chain Monte Carlo (MCMC) simulation. You will also need the rjags library (included in list of R libraries above).
- Introduce participants to methods for quantifying post-fire recovery using satellite data
- Provide an example of using LANDSAT data and covariates to quantify variability in post-fire recovery over the Cape Peninsula of South Africa.
- Workshop overview
- Project Organization
- RStudio
- Git version control
- Introduction to Google Earth Engine
- Data Preparation
- Preparing the data for analysis, calculation of covariates (solar radiation, etc.)
- Solar Radiation: and introduction to GRASS GIS
- Introduction to foreach parallel processing
- Data Prep
- Assembling covariates
- Generating the model data frame
- Exploration of simulated data
- Introduction to bayesian model fitting
- Hierarchical models
- BUGS language
- Modeling Post-fire trajectories