## Splus tutorial

• The material linked to this page was previously used for the Statistics 200 lab course, last taught by Brendan Murphy and John Hartigan in Spring 1998. The labs were created by Brendan Murphy and David Pollard.
• The labs were based on an old version of Splus. Nevertheless, most of the calculations still work with current versions of Splus (and R).
• Directions related to specific directories on the Statlab machines are probably no longer accurate.

### Topics to be covered

Click on the class number to view the corresponding handout for the lab session.
The first five weeks will provide an introduction to S-Plus.
1. [Spring98] Getting into and out of S-Plus. Help! Saving your work. Incorporating S-Plus output in reports. Introduction to lists, vectors, matrices, functions, and graphics. An illustrative example.
2. [Spring98] Reading data from other sources; data from WWW sites (such as StatLib at Carnegie-Mellon University, and the U.S. Census Bureau). Data frames. Evaluation frames. Libraries. Search lists.
3. [Spring98] Fancier graphics: beyond the defaults. Multiple plots per page, split screens, "graphics frames".
4. [Spring98] Matrices, arrays, and factors.
5. [Spring98] More about functions. Default arguments, variable numbers of arguments, return values. Idiot-proofing. Looping and conditional computations.
End of introduction to Splus
6. [Spring98] Data structures. Regression and model fitting. Manipulation of lm objects.
7. [Spring98] Low-level graphics. Construction of customized plots.
8. [Spring98] Fancy pictures: Trellis graphics.
9. [Spring98] Classes and methods.
10. [Spring98] Multivariate plotting.
11. [Spring98] Libraries and dynamic graphics.
12. [Spring98] Special projects.
References:
• Probably the most convenient reference for you will be the help system built into Splus.
• Richard A. Becker, John M. Chambers, and Allan R. Wilks (1988) The New S Language: A programming environment for data analysis and graphics. Wadsworth. [Slightly dated. Just for reference.]
• W. N. Venables and B. D. Ripley (1997) Modern Applied Statistics with S-Plus. (Second edition) Springer-Verlag.
• Phil Spector (1994) An Introduction to S and S-Plus. Duxbury. [Much gentler introduction than Venables&Ripley. No coverage of more recent developments. Very little material specific to Windows version.]
• There is a very active S-news group, where many questions are asked and answered about Splus. Statlib maintains a searchable archive of the discussions that have taken place. Often this site is the best source for particularly puzzling problems with Splus. The list of frequently asked questions is a good place to look for starters.
• Yale FAQ: a collection of explanations to Frequently Asked Questions in Stat 200.