Learning the programming in the new S4 system of classes and methods in R can be quite cumbersome, even though the
methods package is very well documented. Where to look for information on programming with S4 system of classes and methods for R? Here is a open-ended collection of links to resources on learning programming in S4 system. Suggestions more than welcome!
- John M. Chambers. Programming with Data. Springer, New York, 1998. ISBN 0-387-98503-4. Some more info at http://cm.bell-labs.com/cm/ms/departments/sia/Sbook/
- John M. Chambers. Software for Data Analysis: Programming with R. Springer, New York, 2008. ISBN 0387759352, 9780387759357.
Articles and notes
- Short note by John Chambers Classes and Methods in the S Language [PDF] www.omegahat.org/RSMethods/Intro.pdf
- Another note by John Chambers S4 Classes in 15 pages, more or less [PDF]www.stat.ucla.edu/~cocteau/stat202a/resources/docs/S4Objects.pdf
- Slides by Friedrich Leisch from UseR! 2004 conference in Vienna [PDF] http://www.ci.tuwien.ac.at/Conferences/useR-2004/Keynotes/Leisch.pdf
- On R Wiki http://wiki.r-project.org/rwiki/doku.php?id=tips:classes-s4
Sometimes it is worthwhile to look at the source code of the available packages and learn from that. Here is are the packages that can be instructive: stats4, lme4.