replacing the exposed tibble() and data.frame() calls for constructing non-trivial types of inputs with formally-defined classes and generators using S3 or else.
Without it, we are just assuming: 1) the developer always know what an input object has; 2) users always know what they should put into them; 3) users can construct them correctly.
replacing the exposed tibble() and data.frame() calls for constructing non-trivial types of inputs with formally-defined classes and generators using S3 or else.
Without it, we are just assuming: 1) the developer always know what an input object has; 2) users always know what they should put into them; 3) users can construct them correctly.
Reference: https://adv-r.hadley.nz/s3.html
Example: ggplot2::aes https://github.com/tidyverse/ggplot2/blob/main/R/aes.r