[R] To implement OO or not in R package, and if so, how to structure it?
jdnewmil at dcn.davis.ca.us
Thu Sep 14 18:02:11 CEST 2017
I think you should consider whether the advantages of making an object-aware collections class are worth the effort... lists are the standard tool for this task in R, and are normally handled using the functional programming paradigm. Just make sure a sufficiently-complete set of methods are available for the objects you plan to make lists of.
Sent from my phone. Please excuse my brevity.
On September 14, 2017 7:27:55 AM PDT, Alexander Shenkin <ashenkin at ufl.edu> wrote:
>>>> Did you read this?
>>>> Maybe it could give you some insight in how to create package.
>>> That resource is ~9 years old. There are more modern treatments
>>> can read mine at http://r-pkgs.had.co.nz.
>Thanks both. I'm reading through your new book now Hadley... thanks
>that. I'll probably take a shot at building a class to hold one tree
>per object, and search for objects of a class (per
>to implement collections when necessary...
>It does seem like there might be niche out there for a resource for
>folks deciding how to structure their package given what they're trying
>to provide; i.e. should they construct a collection of functions, or
>class defs, or... Could well exist already, and I may just have missed
>R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
>PLEASE do read the posting guide
>and provide commented, minimal, self-contained, reproducible code.
More information about the R-help