Intermediate
R
Q63 / 100
What is the purpose of S3 classes in R, e.g. defining a "print.myclass" method?
Correct! Well done.
Incorrect.
The correct answer is B) S3 is a simple object-oriented system based on generic functions, where methods are dispatched based on the class attribute of an object
B
Correct Answer
S3 is a simple object-oriented system based on generic functions, where methods are dispatched based on the class attribute of an object
Explanation
S3 is R's informal OOP system: a generic function like print() dispatches to a class-specific method (e.g. print.myclass) based on the object's class attribute.
Progress
63/100