Hands-on Research Guide

Data Preparation and Progress Check

A 75-minute project studio with data-preparation tasks, Codex prompts, and independent progress checks.
Published

November 16, 2026

Use this guide to continue Classwork 7 with your research project’s current files. Begin by showing what has changed since your last meeting. Choose one data obstacle to resolve and finish with a result you can explain and reproduce.

NoteToday’s target

Prepare one small, usable piece of project data and verify it. Bring the script, a saved output or diagnostic, one independent check, and a short progress entry to the closing discussion.

Session plan

Monday, November 16, 2026 · 12:30–1:45 p.m.

Minutes Activity Progress checkpoint
0–10 Open current files and show what changed Point to the input, latest code, and an output or error.
10–20 Choose one task and review Codex’s plan State the unit, output, two checks, and one decision.
20–55 Prepare the data and meet with the instructor Show running code and the evidence behind any blocker.
55–70 Rerun and check one result independently Trace a record, value, or matching decision to the source.
70–75 Record the result and the next task Explain what is ready, what remains unresolved, and what you will do next.

Work in your project folder with approved public inputs. Preserve raw files and keep credentials and restricted data outside the shared workspace. If agent access is unavailable, use the prompts as a checklist for your R work.

1. Show where your project stands

Open the current input, latest R script, and most recent output or error. If an input is still missing, open the source documentation or download request.

Give a brief update using this structure.

Since the last meeting, I completed:
The file or output that shows this is:
One input row represents:
The next step is blocked by:
The smallest result I can produce today is:

Keep progress claims tied to files you can inspect. A useful update can include a failed download, an unexpected duplicate, or a documented gap in coverage.

Checkpoint 1. You and the instructor agree on your current stage and the obstacle to address.

2. Choose one data-preparation task

Use the row that fits the files you currently have. A short period, one geographical area, or one variable is usually enough to test the workflow.

Track Starting point One output for today Independent check
A · Acquire a sample An essential input is missing A small raw sample with a source record and retrieval code Read the provider’s definitions and inspect a few downloaded records.
B · Audit an input A raw file is available An intake table covering rows, keys, dates, geography, and missingness Recount one quantity from a small raw subset.
C · Construct the analysis unit Raw rows need aggregation A small airport-day table or a clearly defined moisture predictor Reconstruct one aggregate from its contributing observations.
D · Join prepared sources Inputs have documented units and keys A joined sample with unmatched-key and row-count reports Trace one matched key and inspect an unmatched key if one exists.

If your prepared sample already passes these checks, use the session to produce a coverage table or one descriptive figure. Record its sample and verify one displayed number.

Update your Classwork 7 task card

Use your existing card or project notes to record the current choices.

Chosen track:
Input file(s) and source documentation:
Sample boundaries:
Input observation unit and key:
Output observation unit, key, and file path:
Two checks and their expected results:
One rule I need to decide before implementation:
Condition that should stop the script:

Ask Codex to inspect and propose a plan

Replace the brackets with your paths and choices.

Read my task card at [path] and the source documentation at [path].
Inspect [approved input files or source pages].

Explain what one row represents, the units, the proposed key,
and the sample coverage. Identify missing inputs or unclear definitions.
Propose one R script to produce [output path] and report [two checks].
Identify the research choice that I need to resolve.

Preserve the raw files. Stop after the plan for my review.

Read the relevant definition yourself. Record one decision and its evidence, such as the analysis day, a rate’s denominator, a missing-value code, an aggregation rule, or a predictor’s forecast date.

Checkpoint 2. Before implementation, show the instructor the plan, output path, two expected checks, and your recorded decision.

3. Prepare the data

Choose one of the following prompts after reviewing the plan. Use your project’s existing script names and folders when they are suitable.

Track A · Acquire a small sample

Implement the reviewed retrieval plan for [approved source].
Use [variable, geography, and period] as the sample.
Save the original download under [raw path].
Save the retrieval script at [script path].

Record the provider, direct source page, version if available,
retrieval date, requested subset, units, and access or use terms.
Read the saved file and report its actual rows and coverage.

If access, authentication, or a download queue blocks retrieval,
report the exact blocker and save the request or instructions.
Keep credentials out of scripts and logs.

If access is pending, work with the instructor to prepare the request and audit another available input. A synthetic practice sample can support work on the import and check logic. Label its outputs as synthetic.

Output to inspect. Open the saved sample and source record together. Check that the file’s variables and coverage match the request.

Track B · Audit a raw input

Implement the reviewed audit in [script path].
Read [raw input] using its documented missing-value codes.
Keep identifier columns as text when leading zeros matter.

Save [audit output] with row counts, unique-key counts, repeated keys,
date and geographical coverage, and missingness in the needed fields.
Show example records behind each unexpected result.
Flag unusual values and compare them with the source definitions.
Record proposed cleaning decisions for review.

Run the script and report the exact command and actual check results.

Output to inspect. Pick one audit entry and find the raw observations behind it. Distinguish a missing record, a missing field, and a recorded zero.

Track C · Construct the analysis unit

Implement the reviewed aggregation in [script path].
Read [input] and restrict it to [approved sample].
Construct [output observation unit] using [my approved rule].
Save the result to [derived output].

Report input and output row counts, contributing observations,
missing inputs, and any excluded records.
For a rate, save the numerator and denominator.
For a weighted value, document the weights and coverage.
Stop if the inputs conflict with the approved rule.

Run the script and report the exact command and actual check results.

Output to inspect. Select one output row. Identify its contributing raw rows and reconstruct the calculation separately.

Track D · Make a checked join

Implement the reviewed join in [script path].
Use [keys] and the approved [join type and matching relationship].
Check key completeness and uniqueness before joining.
Report unmatched keys in both directions and row counts before and after.
Stop if the observed matching relationship differs from the plan.

Preserve missing values and source-supported estimates according
to the approved rules. Save the joined sample to [derived output]
and the check report to [check path].

Run the script and report the exact command and actual check results.

Output to inspect. Compare the rows for one key before and after the join. Explain any repeated output rows or sample loss. For a left join, investigate any increase in the starting table’s row count.

During your progress conference

Be ready to show the instructor the following.

  1. The script or command you can run, with its output or exact error.
  2. A source definition that explains a choice in your code.
  3. The smallest unresolved problem and the records or evidence behind it.
  4. The next action you can carry out after the conference.

When the instructor helps retrieve data, save the source details and retrieval instructions in your project. Inspect the downloaded file yourself and explain what each row represents.

Checkpoint 3. By minute 55, have one saved output or a saved diagnostic showing the blocker. Record what actually ran and which checks remain pending.

4. Project examples

These examples illustrate manageable tasks. Choose a sample and definition that fit your own project.

Transportation

Start with one month of flight records for a small set of airports.

  • Confirm whether the input represents departures, arrivals, or another unit.
  • Construct an airport-day table using a documented cancellation definition. Save the numerator, denominator, and count of unknown statuses.
  • Recalculate one day’s cancellation rate from the contributing flight rows.
  • If the task includes smoke, verify the airport-to-county mapping and county-date key. Report missing matches.

Use the public research guide to choose and justify the broader study scope. Transportation research guide

Preseason moisture

Start with one moisture variable for a small geographical area and a few years.

  • Establish its units and whether it represents a particular date, an average, or an accumulated quantity.
  • Record the forecast date and the latest information used to construct the predictor.
  • Agree on the spatial and temporal aggregation before building the predictor.
  • If joining to province-year fire data, report predictor-related missingness and sample loss.

For a province-level aggregate, document the contributing observations and weighting method. Recalculate a small part separately. Moisture research guide

5. Rerun and verify one result

Use minutes 55–70 to check the result yourself.

  1. Rerun the script. Run it from the project root and record the exact command. Use the saved input files to check reproducibility.
  2. Trace one result. Use a hand calculation, direct raw-row inspection, or a separate short R expression.
  3. Compare with the task card. Confirm the sample, units, key, row counts, and expected checks.
  4. Decide how to use the output. State whether you accept it for the intended next step, need a revision, or need more source information.

For example, if your new script is R/13_prepare_data.R, the command is

Rscript --vanilla R/13_prepare_data.R

An agent’s self-check can help identify a problem. Add your own verification using source evidence and record what you observed.

If your check disagrees with the output, investigate the discrepancy and record the unresolved issue. If an input is unavailable, verify the accessible part of the workflow and identify the remaining check.

Checkpoint 4. Show the command, the independent check, its result, and the source observations used.

6. Closing progress record

Use the final five minutes to update lab-notebook.md or your existing project notes.

November 16, 2026

Task and intended use:
Input and output paths:
What Codex helped with:
What I decided and the evidence for it:
Command actually run:
Checks actually completed and their results:
My separate check and the source evidence:
What is ready to use:
Remaining blocker or limitation:
Next task for Wednesday, November 18:
Help or input needed:

Checkpoint 5. Open your output or failing check and give a brief handoff. Explain what changed today and the next concrete task.

Use the script, source record, check results, and decisions as evidence when preparing your progress report. Progress-report expectations

Reference

Classwork 7 supplies the full plan–implement–verify workflow. The worked synthetic example shows an exact duplicate decision, a checked left_join(), and a separate raw-row check.

Back to top