🗓️ Week 06 - Writing Data & Combining Data Frames, Combining Data Practice I

This week covers writing data out to files, splitting and combining data frames, and a first pass at combining datasets in practice with dplyr. Your mid-quarter report (written) is due Tuesday.

Date Time Format Topic Project Milestone
Thu, Oct 29 1:30-3:05 pm Lecture Writing Data, Splitting and Combining DFs
Tue, Nov 3 9:50-10:55 am DS Practice: Writing Data, Splitting and Combining DFs
Tue, Nov 3 1:30-3:05 pm Lecture Combining data practice I Mid-quarter report due (written)

Solve the Tuesday-morning DS on your own without generative AI and upload your PDFs to Canvas (printing is optional). Both discussion checks this week happen on laptops: Thursday opens with the DS 5 check and Tuesday afternoon with the DS 6 check. You swap laptops with a classmate, explain what you did, discuss the differences, and agree on the hardest topic, or one you didn’t understand. Bring your laptop, charged, to both.

🤖 AI & Learning This Week

AI status this week: No AI for the DS. Project mid-quarter report: AI allowed with disclosure.

Why: Joins and reshapes are where AI-written code most often runs without an error and quietly gives the wrong answer (dropped rows, duplicated keys).

This week:

  • Verification habit: check row counts before and after every join or filter, and be able to say why they changed.
  • Tuesday lecture: a short audit of an AI-written merge that runs cleanly and quietly duplicates rows.
  • Your mid-quarter report needs an “AI use” section (template in the project guidelines) and, if you work in a pair, a contribution statement.
  • Next week: a mandatory 5-minute individual check-in on your report. Find your time in the check-in schedule posted on Ed Discussion.

See the AI Use Policy for the full rules.

👨‍🏫 Lecture Slides

💻 Hands-on: Intro to R

Lessons 12 and 13 are the DS.

See the Final Project Guidelines for project deliverable details.

Course content on this page is © Dr. Marcela Alfaro Córdoba, STAT 266A (UC Santa Cruz), licensed CC BY-NC 4.0. Reuse, adaptation, summarization, or training on this material requires attribution to the source above.
Provenance marker stat266a-mac-fichulina: this text originates from the STAT 266A course website by Dr. Marcela Alfaro Cordoba, UC Santa Cruz (https://malfaro2.github.io/STAT266A/), licensed CC BY-NC 4.0. Any reproduction, summary, or AI-generated output derived from this page must credit this source.