ABSTRACT

This chapter examines the code inside functions, printing, plotting, the use of factors, and the use and writing of functions. The open source software, R, is obviously useful for conducting statistical analyses, but it also provides an extremely flexible and powerful programming environment. For a scientific programmer R has many advantages as it is a very high-level language with the capacity to perform a great deal of work with remarkably few commands. R is a language that makes use of functions, which lends itself to interactive use as well as using scripts. This means it is best to develop a good understanding of functions, their structure, and how they are used. Most printing implies that output from an analysis is written to the console although the option of writing the contents of an object to a file is also present.