Welcome to the home page for the 2024 UMN Multilevel Modeling and Climate Data workshop.
This GitHub repository contains presentation slides and other materials that will be used in the workshop.
Below we describe some setup work that can be completed before the workshop itself. Please follow the instructions in advance of the workshop. If you have trouble, we may be able to use some time at the beginning of the workshop to assist in some of these steps. However, some steps (i.e. registering for access to IPUMS DHS) require some waiting time, so it will be best if you can complete them in advance.
All data and software used in the workshop are available free of charge.
To obtain access to IPUMS DHS, you must first register for data access through the DHS Program itself.
Once you have a valid DHS account, you can log into IPUMS DHS using your DHS username and password. 🔑
You can generate a data extract containing the same samples and variables that are used in this workshop through your own IPUMS DHS account.
If you’re new to IPUMS DHS, click here for instructions on building an IPUMS DHS data extract.
- To reproduce the data used in this workshop, select the following
samples and variables:
- Sample: Kenya 2014 🇰🇪
- Variables:
BIRTHWT
HEIGHTFEM
KIDSEX
KIDDOBCMC
BIRTHWTREF
FLOOR
TOILETTYPE
DRINKWTR
HWHAZWHO
FEVRECENT
DIARRECENT
- Submit your extract request through the IPUMS DHS interface.
- When the it has finished processing,
download
the completed data extract.
- You will need to download two files (
.dat.gz
and.xml
). See the download instructions for information about how to obtain each. - Save both files into this project’s
data
sub-directory
- You will need to download two files (
If you do not already have R and RStudio installed:
- Install R by clicking the appropriate link(s) for the operating system you’re running.
- Install RStudio by clicking the Download RStudio Desktop button.
There are 2 options for downloading the files used in this workshop:
- Download
the workshop files manually
- 📂 Open the downloaded zip file
- 🚨 Windows users may also need to download decompression software (e.g. 7-Zip) to decompress the zip file.
- Otherwise, if you’re comfortable with Git, run the following code in your terminal to clone this repository into the local directory of your choice:
git clone https://github.com/IPUMS-Global-Health/umn-nairobi-2024.git
Open the file umn-nairobi-2024.Rproj
found in this project folder.
This will launch the workshop project in a new RStudio environment. 🚀
Copy the following code into the Console
in RStudio, then press
Enter
.
# Install necessary packages if not already installed
pkgs <- c("tidyverse", "ipumsr", "sf", "terra",
"ggspatial", "patchwork", "lubridate", "lme4")
for (pkg in pkgs) {
if (!require(pkg, quietly = TRUE, character.only = TRUE)) {
install.packages(pkg)
}
}
It may take a few minutes to install the packages needed for this workshop ⌛
- If prompted to update dependency packages, please do so by pressing
1
. - If asked
Do you want to install from sources the package which needs compilation?
, reply No - Restart R at least once before the workshop begins. Do so by clicking Session > Restart R in the header toolbar.
You should now be ready to follow along with the workshop!
Workshop slides were built with Quarto and Revealjs.