What is the S4 object system and how do setClass, setGeneric, and setMethod work?
Role: Data Scientist
Category: Data Manipulation (SQL/Python)
Difficulty: medium
Interview Round: Other
Overview: Asks what R's S4 object system is and how setClass, setGeneric and setMethod define classes, generic functions and methods. Tests understanding of typed slots, validity checks, inheritance and method dispatch, and how S4 compares with S3.