How does aggregate() work in base R and how does it relate to split-apply-combine?
Role: Data Scientist
Category: Data Manipulation (SQL/Python)
Difficulty: easy
Interview Round: Other
Overview: Asks how the base R aggregate() function groups rows, applies a summary function and returns a data frame, and how that maps to split-apply-combine. It tests the formula and by-list interfaces, missing value handling and when to reach for dplyr or tapply.