MOCK, teaching version of an HFC pipeline, used in the Data Quality session
(Thursday, July 23). It runs on fake data built to match the
Household Water Questionnaire – V1 (see documentation/), the same case
study used in the Data Ingestion, Cleaning & Tidying session.
main.do sets globals and runs one numbered do-file per check from code/.
Each check exports its flags to one sheet of output/YYYY-MM-DD_HFC_Household_Water.xlsx
— the report a field team would actually read.
Files 1 (import), 2 (duplicates) and 7 (dashboard) are completed, as a model of the style we use. Files 3–6 contain "YOUR TURN" stubs for you to complete during the exercise, using the DQAP your table filled in.
- Install GitHub Desktop and sign in.
- Clone this repository: green Code button → Open with GitHub Desktop.
- In GitHub Desktop, create a new branch named after your table
(e.g.
table-3oryourname-hfc). Work there, never onmain. - Open
main.doin Stata, add your username and file path to Section 2 (typedi c(username)in Stata to see your machine's name), and run it end to end once as-is. - Complete do-files
code/3-missingness.dotocode/6-surveylogic.do(look for theYOUR TURNcomments), re-runningmain.doas you go. - When everything runs, commit your changes in GitHub Desktop
(do-files + today's report in
output/), push your branch, and open a pull request tomainso the facilitators can review your code. Full workflow details: seeCONTRIBUTING.md.
- On the repository page, green Code button → Download ZIP.
- Extract it anywhere on your computer.
- In Stata:
cdinto the extracted folder, thendo main.do. (With no username match,main.dofalls back to the current working directory, no path edits needed.) - Complete do-files 3–6 the same way. You just won't be able to push; flag a facilitator at the end and we'll look at your code together.
main.do runs everything (edit Section 2 paths first)
code/ one numbered do-file per check (+ ado/ for packages)
data/raw/ household_water_fake_raw.csv (fake!), _use.dta is local
documentation/ the questionnaire + the formatted report template
output/ today's excel report lands here
- Stata 15 or newer. User-written commands (
ieboilstart) are shipped incode/ado/and wired up bymain.do, nothing to install.
Development Innovation Lab · University of Chicago