How do Reference Classes (R5) and R6 differ from S3 and S4, and when would you use each?
Role: Data Scientist
Category: Data Manipulation (SQL/Python)
Difficulty: medium
Interview Round: Other
Overview: Asks how the R reference class systems, Reference Classes and R6, differ from the S3 and S4 object systems, and when each one fits. Tests value versus reference semantics, method dispatch, and practical judgment about object design in R.