*** empty log message ***
[ess.git] / doc / ess-intro.tex
blob742493838982f252fb67b80a722eb9719e8214ca
1 \documentclass{article}
3 \newif\ifMM\MMtrue
4 \MMfalse
5 \newif\ifdraft
6 % During writing: a draft:
7 %\drafttrue
8 % FINAL:
9 \draftfalse \ifMM\drafttrue\fi
11 \ifdraft %% generate tableofcontents down to the \paragraph
12 \setcounter{tocdepth}{5}
13 \fi
14 %1. introduction
15 % a) a statistician's needs
16 % b) statistical analysis packages supported by ESS
17 %2. emacs
18 % a) buffers
19 % b) key sequences
20 % c) modes
21 % 1) font-lock
22 % 2) shell/comint
23 % 3) ange-ftp/EFS/tramp
24 % 4) vc/pcl-cvs
25 %3. ESS
26 % a) interactive
27 % 1) S family
28 % 2) SAS
29 % b) batch
30 % 1) SAS
31 % 2) BUGS
32 % 3) S family
33 %4. ESS as an open-source project
34 % a) origins
35 % 1)S-mode
36 % 2)SAS-mode
37 % b) unification
38 % 1)ESS-mode
39 % 2)Emacs/XEmacs
40 % 3)Unix/Windows/Mac
41 %5. conclusion
42 % a) summary
43 % b) what's next for ESS
44 % ESS internet resources
45 % a) home page
46 % b) ess-help
47 % c) anonymous cvs
48 % References
50 \ifdraft
51 \addtolength{\topmargin}{-1cm}
52 \addtolength{\textheight}{+1cm}
53 \else%FINAL:
54 \renewcommand{\baselinestretch}{1.5}
55 \fi
56 \addtolength{\oddsidemargin}{-0.5in}
57 \addtolength{\textheight}{0.2in}
58 \addtolength{\textwidth}{1in}
59 \ifMM\addtolength{\textheight}{2cm}\fi
61 %%%
62 \usepackage[authoryear,round]{natbib}
63 %or (if you have an unshiny latex installation)
64 %\newcommand{\citep}[1]{{\{\sf#1\}}}
65 %%%
66 \usepackage{alltt}
68 %% Postscript fonts
69 \usepackage{times}
70 \usepackage{graphicx}
71 %\usepackage{psfig}
73 \ifx\pdfoutput\undefined
74 %% Stuff wout hyperref
75 \def\url#1{\stexttt{#1}} % To help fit in lines ?AJR: stextsf?
76 \else
77 %% Stuff with hyperref
78 \usepackage{hyperref}
79 %%\hypersetup{backref,colorlinks=true,pagebackref=true,hyperindex=true}
80 \hypersetup{backref,colorlinks=false,pagebackref=true,hyperindex=true}
81 \fi
82 %%---End of package requiring ---------- Own Definitions -------------
84 \newcommand*{\regstrd}{$^{\mbox{\scriptsize{\textregistered}}}$}
85 \newcommand*{\tm}{$^{\mbox{\scriptsize\sc tm}}$}
86 \newcommand*{\SAS}{\textsc{SAS}}
87 \newcommand*{\Splus}{\textsc{S-Plus}}
88 \newcommand*{\XLispStat}{\textsc{XLispStat}}
89 \newcommand*{\Stata}{\textsc{Stata}}
90 \newcommand*{\Rgui}{\textsc{Rgui}}
91 \newcommand*{\Perl}{\textsc{Perl}}
92 \newcommand*{\Fortran}{\textsc{Fortran}}
93 \newcommand*{\Scmt}[1]{\hbox{\qquad {\footnotesize \#\#} \textsl{#1}}}
94 \newtheorem{defn}{Definition}[section]
95 \newtheorem{ex}{Example}[section]
97 \newcommand{\stexttt}[1]{{\small\texttt{#1}}}
98 \newcommand{\ssf}[1]{{\small\sf{#1}}}
99 \newcommand{\elcode}[1]{\\{\stexttt{\hspace*{2em} #1}}\\}
100 \newcommand{\file}[1]{`\stexttt{#1}'}
101 \newcommand{\US}{{\char'137}} % \tt _
102 \newcommand{\marpar}[1]{\marginpar{\raggedright#1}}
103 \newenvironment{Salltt}{\small\begin{alltt}}{\end{alltt}}
105 \newcommand{\emptyfig}{
106 \hspace*{42pt}\rule{324pt}{.25pt}\\
107 \hspace*{42pt}\rule{.25pt}{10pc}
108 \rule{316pt}{.25pt}
109 \rule{.25pt}{10pc}}
111 \ifMM\newcommand{\ESSfig}[1]{\centering{#1}}
112 \else\newcommand{\ESSfig}[1]{\centering\ifdraft\emptyfig\else{#1}\fi}
115 %% Use \begin{Comment} .. \end{Comment} for internal comments
116 \ifdraft
117 \newenvironment{Comment}{\begin{quote}\small\itshape }{\end{quote}}
119 \else %% this requires
120 \usepackage{verbatim}
121 \let\Comment=\comment
122 \let\endComment=\endcomment
126 %%--------------------------------------------------------------- Start Text
128 \title{Emacs Speaks Statistics (ESS): A multi-platform, multi-package
129 intelligent environment for statistical analysis}
131 %%For blinded submission:
132 %\author{anonymous}
134 %%For regular review:
135 \author{A.J. Rossini \and Richard M. Heiberger \and Rodney A. Sparapani
136 \and Martin M{\"a}chler \and Kurt Hornik \footnote{%
138 A.J. Rossini is Research Assistant Professor in the Department of
139 Biostatistics, University of Washington and Joint Assistant Member at
140 the Fred Hutchinson Cancer Research Center, Seattle, WA, USA
141 \url{mailto: rossini@u.washington.edu};
143 Richard M. Heiberger is Professor in the Department of Statistics at
144 Temple University, Philadelphia, PA, USA \url{mailto: rmh@temple.edu};
146 Rodney A. Sparapani is Senior Biostatistician in the Center for Patient
147 Care and Outcomes Research at the Medical College of Wisconsin,
148 Milwaukee, WI, USA \url{mailto: rsparapa@mcw.edu};
150 Martin M{\"a}chler is Senior Scientist and Lecturer in the Seminar for
151 Statistics, ETH Zurich, Zurich, Switzerland
152 \url{mailto: maechler@stat.math.ethz.ch};
154 Kurt Hornik is Professor in the Institut f{\"u}r Statistik,
155 Wirtschaftsuniversit{\"a}t Wien and the Institut f{\"u}r
156 Wahrscheinlichkeitstheorie und Statistik, Technische Universit{\"a}t
157 Wien, Vienna, Austria \url{mailto: Kurt.Hornik@R-project.org}}}
159 %%\date{\today}
160 \date{$ $Date: 2003/10/22 17:34:04 $ $\tiny Revision: 1.255$ $}
162 \begin{document}
164 %%\ifpdf
165 %% \DeclareGraphicsExtensions{.jpg,.pdf,.png,.mps}
166 %%\fi
167 %%%% To cite everything
168 %%\nocite{*}
170 \ifdraft
171 \setcounter{page}{0}
172 %%\newpage
173 \tableofcontents
176 \maketitle
178 \ifdraft{}%% large line skip -- not for draft
179 \else%FINAL:
180 \renewcommand{\baselinestretch}{1.5}
181 %%- \baselineskip=2pc
184 \begin{abstract}
185 Computer programming is an important component of statistics
186 research and data analysis. This skill is necessary for using
187 sophisticated statistical packages as well as for writing custom
188 software for data analysis. Emacs Speaks Statistics (ESS) provides
189 an intelligent and consistent interface between the user and
190 software. ESS interfaces with SAS, S-PLUS, R, and other statistics
191 packages under the Unix, Microsoft Windows, and Apple Mac operating
192 systems. ESS extends the Emacs text editor and uses its many
193 features to streamline the creation and use of statistical software.
194 ESS understands the syntax for each data analysis language it works
195 with and provides consistent display and editing features across
196 packages. ESS assists in the interactive or batch execution by the
197 statistics packages of statements written in their languages. Some
198 statistics packages can be run as a subprocess of Emacs, allowing
199 the user to work directly from the editor and thereby retain a
200 consistent and constant look-and-feel. We discuss how ESS works and
201 how it increases statistical programming efficiency.
202 \end{abstract}
204 \noindent Keywords: Data Analysis, Programming,
205 S, \SAS, \Splus, R, \XLispStat, \Stata, BUGS, Open Source Software,
206 Cross-platform User Interface.
208 \section{Introduction}
209 \label{sec:introduction}
211 Most statistical research activities, particularly data analysis and
212 communication, involve some form of computing. The computer user
213 interface is thus placed in the central role of facilitating
214 statistical tasks. While presentation of character and graphical
215 information is the most visual component of a user interface,
216 perhaps a more critical component is how the computer interprets user
217 input. A familiar, well-understood set of input behaviors can provide
218 large gains in efficiency. This paper introduces Emacs Speaks
219 Statistics (ESS) \citep{ESS}, a software package which provides a
220 common interface to a variety of statistical packages on the most
221 common computing platforms.
223 ESS is an interface to statistical packages that provides tools which
224 facilitate both statistical software development and data analysis.
225 ESS provides assistance with both writing and evaluation of analysis
226 code for both interactive and batch statistical packages. ESS
227 currently supports the S family of languages (including S
228 \citep{BecRCW88,ChaJH92,ChaJ98}, \Splus\regstrd\ \citep{Splus}, and R
229 \citep{ihak:gent:1996,R}; \SAS\regstrd\ \citep{SAS:8}; \Stata\
230 \citep{Stata:7.0}; \XLispStat\ \citep{Tier90} and its extensions Arc
231 \citep{Cook:Weisberg:1999} and ViSta \citep{youn:fald:mcfa:1992}; BUGS
232 \citep{BUGS}; and Omegahat \citep{DTLang:2000}. ESS can be extended
233 to accommodate most statistical packages which provide either an
234 interactive command-line or process batch files for instructions.
236 We start by describing the Emacs text editor, the underlying platform
237 on which ESS is built. Next, we discuss how ESS enhances a
238 statistician's daily activities by presenting its features and showing
239 how it facilitates statistical computing. We conclude with a short history
240 of the development of ESS.
241 % and conclude with future extensions and related work.
243 \section{Emacs}
244 \label{sec:emacs}
246 Emacs is a mature, powerful, and extensible text editing system which
247 is freely available, under the GNU General Public License (GPL), for a
248 large number of platforms, including most Unix\regstrd
249 distributions, Microsoft Windows\regstrd\ and Apple Mac\tm\ OS. There
250 are two open-source implementations of Emacs: GNU Emacs
251 \citep{GNU-Emacs} and XEmacs \citep{XEmacs}. Emacs shares many
252 features with word processors, and some characteristics with operating
253 systems, including many facilities which go beyond ordinary text
254 editing. More important to our goals, Emacs can control and interact
255 with other programs.
257 \paragraph{Keyboard and Mouse Input.}
258 When Emacs was originally written, character-based terminals were the
259 most advanced method of computer access. Common Emacs commands were
260 mapped to key sequences, creating keyboard shortcuts for convenience.
261 Over the last decade, Emacs has been extended to use graphical
262 windowing systems, such as X11\tm, Microsoft Windows, and Apple Mac
263 OS, which allow additional forms of input, for example using a mouse,
264 and which encourage multiple applications to share a single display.
265 Presently, Emacs is more often used with a GUI, with commands bound to
266 mouse actions, but having commands also associated with key sequences
267 is an important ergonomic and time-saving feature. Emacs menus and
268 toolbars on the display screen allow mouse access to frequently used
269 actions and provide a graphical alternative when the user does not
270 know or can not recall a key sequence; these are also subject to
271 user-customization.
273 \paragraph{Buffers give Emacs control.}
274 Emacs buffers are the interface between the user and computer. They
275 can be considered to be a collection of scratch pads that both the
276 user and computer can read, write, and respond to. The user can
277 simultaneously edit many files and control numerous programs by
278 opening multiple buffers. With disk files, the working copy of the
279 opened file is placed in an Emacs buffer where it can be viewed and
280 edited either by the user or automatically by Emacs or another program
281 under the control of Emacs. Emacs can save a backup of the contents
282 to disk at specified intervals. Emacs presents buffer contents in
283 ways which optimize reading and navigation activities. One example of
284 program control is the embedding of the interactive operating system
285 command line interpreter, called a shell, within Emacs. Variations on
286 this theme are used to control programs such as statistical packages
287 which take input from and provide output to the command-line. The
288 resulting buffers provide a copy of the entire transcript of the
289 interaction, which can be edited and searched while the program
290 executes.
292 \paragraph{Major and Minor Modes.}
293 Emacs capabilities are extended by loading
294 %% AJR: If we remove ``or byte-compiled'' we need to remove ``text'',
295 %% since it is wrong.
296 %% text
297 %% or byte-compiled
298 files containing commands and functions written in Emacs Lisp (elisp)
299 \citep{RChassell1999}, which is a dialect of Lisp
300 \citep{PGraham:1996}. Emacs commands can be called interactively by
301 pressing a key sequence mapped to the command or by name.
302 %% AJR: this is actually true for M-x long-command-not-bound-to-keys,
303 %% but I'm not telling anyone this!
304 % Rodney: I don't understand what the problem is with telling them.
305 The most important extensions to Emacs take the form of modes, which
306 provide specific enhancements to the editing behavior.
308 Major modes provide a customized environment consisting of mapped key
309 sequences and associated commands for performing tasks such as file
310 editing, reading mail, or browsing disk directories. Only one major
311 mode can be active for a given buffer at any time. Major modes also
312 can be written to intelligently control other programs such as
313 statistics packages. Major modes for file editing are often
314 determined by the file type or extension, i.e. the characters at the
315 end of the file name that follow a period like \stexttt{txt},
316 \stexttt{s}, or \stexttt{sas}. Examples of this kind of major mode are
317 \stexttt{ESS[S]} and \stexttt{ESS[SAS]}. Major modes understand a
318 file's syntax and grammar and therefore provide intelligent
319 actions such as automatic indentation; navigation in units of
320 characters, words, lines, sentences, paragraphs, function definitions,
321 and pages; syntax-based fontification and colorization; and
322 reformatting based on programmed conventions.
324 Minor modes provide complementary services that that are applicable
325 across major modes. Many minor modes can be active at once. For
326 example, \stexttt{font-lock-mode} allows Emacs to highlight, with
327 fonts or colors, the syntax of a programming language whose
328 characteristics are described within a major mode like
329 \stexttt{ESS[S]}. The \stexttt{overwrite-mode} determines whether
330 typed characters replace the existing text or are inserted at the
331 cursor. Minor modes can emulate the key sequences used by another
332 editor such as \stexttt{vi}. In addition, they can be used to perform
333 version control operations and many other operations which are nearly
334 identical across file types.
336 \paragraph{Network Support.}
337 Emacs allows transparent access to remote files over a network. This
338 means that the user views, edits, and saves files on a remote machine
339 exactly as if they were on the local machine. Mechanisms for both
340 open (\stexttt{ange-ftp} and \stexttt{EFS} use ftp) and secure
341 (\stexttt{tramp} uses scp or ssh) access are available. Emacs can
342 also monitor and control remote processes running in a shell buffer.
344 \paragraph{Editing Extensions.}
345 Most programming and documentation tasks consist of editing text.
346 These tasks can be enhanced by contextual highlighting and recognition
347 of special reserved words appropriate to the programming language in
348 use. In addition, Emacs also supports folding, outlining, tags, and
349 bookmarks, all of which assist with maneuvering around a file. Emacs
350 shares many features with word processing programs and cooperates with
351 markup-language document preparation systems such as \LaTeX,
352 \textsc{html}, or \textsc{xml}.
354 Tracking changes to a text file made by multiple users, potentially in
355 different locations, is the job of source-code control programs.
356 Emacs interacts with standard source-code control programs such as CVS, RCS,
357 and SCCS through minor modes such as \stexttt{vc-mode}. These
358 source-code control systems facilitate documenting and tracking edits and
359 changes to a file. More importantly, they allow for branching and
360 merging of versions so that material present in an older version of
361 the file can be recovered and inserted into a newer version in a
362 fairly easy manner.
364 \begin{figure}[tbp]
365 % \ESSfig{\includegraphics[angle=270,width=\textwidth]{ediff-sas}}
366 \url{http://www.analytics.washington.edu/downloads/ess/doc/figures/ediff-sas.gif}
367 \caption{Ediff of two versions of a file.}
368 \label{f.ediff}
369 \end{figure}
371 Comparison of files, two or three drafts of a paper for example, is
372 simplified by \stexttt{ediff}. An example is shown in Figure
373 \ref{f.ediff}. The lines that are similar are highlighted in the two
374 buffers, one for each file, and the specific words that mismatch are
375 highlighted in a contrasting color. \stexttt{ediff} has many tools
376 for working with the differences in files and in entire directories.
377 When combined with the patch utility or a source-code control system,
378 it provides the user with the ability to insert, delete or modify only
379 the differing portions of text files.
381 % Rodney: You can't just mention complex functionality like etags and
382 % speedbar. We would need to introduce these packages. Since they
383 % aren't critical to ESS at this time, let's ignore them.
384 Emacs has many other important features. Emacs provides file-manager
385 capabilities, such as \stexttt{dired} (discussed in Major and Minor
386 Modes above) and \stexttt{speedbar}, both of which interface to the
387 computer's directory structure. Emacs stores the complete history of
388 commands issued in an editing session, allowing a flexible and fairly
389 complete undo capability. More importantly, for modes which control
390 processes, the process input history is stored for recall as well as
391 for later editing for printing or re-use. Emacs also includes web
392 browsers, mail/newsgroup readers, and spell checking.
394 In addition to being an extremely powerful editor, Emacs also
395 includes capabilities usually found in an operating system. Thus, it
396 provides a strong foundation for constructing an integrated
397 development environment focused on the needs of statisticians. Emacs'
398 power, flexibility, portability, and extensibility make it a solid
399 platform on which to construct a statistical analysis user interface.
401 \section{ESS extends Emacs}
402 \label{sec:ess-extends-emacs}
404 Statistical programming is the writing of computer programs for data
405 analysis and processing. These programs might be written in a
406 computer language that requires a compiler, such as \Fortran\ or C.
407 But, more likely, they are written in a statistical analysis language
408 that only requires an interpreter such as R, \SAS, \Stata, or \XLispStat.
409 General purpose languages such as \Fortran, C/C++, Java, and PERL
410 have integrated development environments which facilitate writing and
411 debugging code.
413 ESS extends Emacs to provide an integrated development environment for
414 statistical languages. It offers a single
415 interface for a variety of statistical computing tasks including
416 interactive data analysis and statistical programming.
417 ESS is able to provide a functional and extensible interface
418 which is uniform and consistent across multiple statistical packages.
419 This is done by adding shortcuts and features for accelerated editing
420 of files as well as by interacting with the particular statistical
421 packages to provide, for example, control of input/output, assistance
422 with evaluation, and specialized parsing of help files.
424 ESS supports the S family (S, \Splus, and R) interactively. \SAS\ and
425 BUGS are also well supported for batch processing. \Stata\ and
426 \XLispStat\ (including ARC and ViSta) are supported through
427 highlighting and process-interfacing.
429 \subsection{Features and capabilities}
430 \label{sec:ESS:features}
432 \paragraph{Syntactic highlighting and indentation of source code.}
433 The programmers task is eased when language constructs (such as
434 reserved words, function calls, strings, and comments) are visually
435 identifiable and when lines of code are automatically indented to a
436 depth appropriate to their context (e.g., if--then clauses, loops).
437 ESS provides both of these to the programmer by including a
438 description of the syntax of each supported statistical language in
439 the form used by \stexttt{font-lock-mode}.
441 Figure \ref{f.font} shows an example of font-locking a complicated S
442 statement. The top panel shows an \stexttt{if} statement with a long
443 expression in the condition and a multi-line consequence. The keyword
444 \stexttt{if} is shown in purple, the string \stexttt{"deltat"} in
445 RosyBrown. The comments are in red. Everything else is in the
446 standard font. The consequence is indented and the continuations of
447 the consequence are further indented. The matching parentheses are
448 shown in green. The cursor is indicated by a solid box. In the
449 bottom panel, we replaced the matching parenthesis with an unbalanced
450 bracket. Emacs immediately marks that with the paren-mismatch font,
451 bright purple in this example. On a black and white terminal we would
452 use bold, underline, italic, and reverse-video, rather than colors, to
453 distinguish the fonts.
455 % Figure \ref{f.font} shows a black-and-white example of font-locking a
456 % complicated S statement. The top panel shows an \stexttt{if}
457 % statement with a long expression in the condition and a multi-line
458 % consequence. The keyword \stexttt{if} is shown in an underlined font,
459 % the string \stexttt{"deltat"} in an italic underlined font. The
460 % comments are in an italic font. Everything else is in the standard
461 % font. The consequence is indented and the continuations of the
462 % consequence are further indented. The matching parentheses are marked
463 % by a bold foreground and a shaded background. The cursor is indicated
464 % by a solid box. In the bottom panel we replaced the matching
465 % parenthesis with an unbalanced bracket. Emacs immediately marks that
466 % with the paren-mismatch font, bright purple on
467 % a color terminal.
469 The font selection and the indentation depth are automatically
470 supplied by Emacs as the lines are typed. The user has several
471 options for mapping of colors or fonts to each of the syntactic types.
472 We selected
473 % black-and-white font-mapping for display here. On a color terminal
474 % we might use
475 purple for the keywords, red for comments, green for matching parens,
476 and inverse-video purple for mismatched parens. Emacs makes default
477 choices of colors and ESS provides several other optional schemes.
479 \begin{figure}[tbp]%h
480 % \ESSfig{%
481 % \includegraphics[angle=270,width=\textwidth]{font-cor-s}
482 % \includegraphics[angle=270,width=\textwidth]{font-incor-s}%
484 \url{http://www.analytics.washington.edu/downloads/ess/doc/figures/font-cor-s.jpg}
485 \url{http://www.analytics.washington.edu/downloads/ess/doc/figures/font-incor-s.jpg}
486 \caption{We illustrate here with fonts and colors appropriate for a
487 color display. On a black and white terminal we would use bold,
488 underline, italic, and reverse-video. On a color terminal we
489 would use a selection of colors.}
490 \label{f.font}
491 \end{figure}
493 Since S syntax is similar to that of C, ESS uses the Emacs tools for
494 reformatting S code to match particular styles. Common C format styles,
495 as well as locally customized styles, are defined by specifying the indentation
496 level for nested statements, location of open-braces (at the end or at the
497 beginning of a line), indentation offsets for if-then-else constructs,
498 and similar characteristics.
500 Syntax highlighting can be used to help enforce coding
501 standards. Figure \ref{f.hilock} illustrates a standard for
502 \SAS\ programming that says all \stexttt{PROC} statements must use the
503 \stexttt{DATA=datasetname} option.
505 \begin{figure}[tbp]
506 % \ESSfig{\includegraphics[angle=270,width=\textwidth]{hilock-sas}}
507 \url{http://www.analytics.washington.edu/downloads/ess/doc/figures/hilock-sas.gif}
508 \caption{Enforce coding standards. The standard here is
509 that all \stexttt{PROC} statements must use the
510 \stexttt{DATA=datasetname} option. Lines that satisfy the
511 standard turn green, lines that don't turn red.
512 Ambiguous ones turn yellow.}
513 \label{f.hilock}
514 \end{figure}
516 \paragraph{Process interaction.}
517 Emacs has historically referred to processes under its control as
518 ``inferior'', accounting for the name inferior ESS (\stexttt{iESS}) to
519 denote the mode for interfacing with the statistical package. Figure
520 \ref{f.ess-demo} shows the S language program \stexttt{ess-demo.s} in
521 the top buffer in \stexttt{ESS[S]} mode and the executing R process in
522 the bottom buffer \stexttt{*R*}. The \stexttt{iESS} major mode of the
523 \stexttt{*R*} buffer is crafted for command-line editing. This mode
524 remembers and uses the command history, allowing for the recall and
525 searching of previously entered commands. Filename completion for
526 local directories is also available.
528 \begin{figure}[tb]
529 % \ESSfig{\includegraphics[angle=270,width=\textwidth]{ess-demo}}
530 \url{http://www.analytics.washington.edu/downloads/ess/doc/figures/ess-demo.jpg}
531 \caption{Line-by-line execution of a command file. The cursor is
532 placed on a line in the \stexttt{ESS[S]} buffer and then with a single
533 key sequence
534 the line is sent to the \stexttt{*R*} buffer for
535 execution. The output of the package goes directly to the
536 editable \stexttt{*R*} buffer.}
537 \label{f.ess-demo}
538 \end{figure}
540 \paragraph{Source-level Debugging.}
541 ESS facilitates the editing of source code files, sets of commands
542 written for a statistical analysis package, and allows the user to
543 load and error-check small sections of source code into the package.
544 This is done through several mechanisms. First, the presence of
545 unbalanced parentheses or mismatched/unterminated quotes is
546 immediately evident with syntactic highlighting of the source code.
547 Second, functions are provided for simple and consistent execution of
548 user-specified or natural units of the code (function definitions in S
549 or \XLispStat, \stexttt{PROC \dots\ RUN;} sections in \SAS). An
550 error-free evaluation lets the user execute the next section of code;
551 if errors arise, the user edits the current unit and re-evaluates.
552 Once the code is verified, an entire buffer, or file, of code can be
553 sent to the package as a unit. This file can also be used as a batch
554 file for routine analysis at a later time. Finally, output from the
555 statistics package is normally captured directly by Emacs and placed
556 into a buffer from where it can be edited and searched. Particular
557 forms of output such as requests for help pages and log-file output
558 can be diverted into special buffers with modes crafted to facilitate
559 reading. These modes include tools for automatically placing the
560 cursor on the first \stexttt{ERROR}, for example in \SAS\ and S.
562 \paragraph{Interactive transcripts.}
563 A transcript records all commands entered by the analyst and the
564 corresponding text-based responses such as tables and comments
565 generated by the statistics package during an interactive statistical
566 analysis session. Once a transcript file is generated, for example by
567 saving an \stexttt{iESS} buffer, \stexttt{transcript-mode} assists
568 with reuse of part or all of the entered commands. ESS understands
569 the transcript's syntax, especially the potential prompt patterns used
570 during the interactive analysis. ESS provides tools to facilitate
571 editing and re-evaluating the commands directly from the saved
572 transcript. This is useful both for demonstration of techniques and
573 for reconstruction and auditing of data analyses. Special ESS
574 functions can ``clean'' S language transcripts by isolating all input
575 lines and placing them in a new S language source file. Transcript
576 cleaning facilitates the use of an exploratory interactive analysis
577 session to construct functions and batch files for routine analysis of
578 similar data sets.
580 \paragraph{Remote access to statistics packages.}
581 ESS provides transparent facilities for editing files and running
582 programs which might reside on numerous remote machines during the
583 same session. The remote machine could be a different platform than
584 the local machine.
586 \paragraph{Manipulating and Editing Objects (S family).}
587 For languages in the S family, ESS provides object-name completion of
588 both user- and system-defined functions and data. ESS can dump and
589 save objects (user- and system-generated) into formatted text files,
590 and reload them (possibly after editing).
592 \paragraph{Help File Editing (R).}
593 ESS provides an R documentation mode (\stexttt{Rd-mode}) which assists
594 in writing help files for R functions, objects, and other topics worth
595 documenting. \stexttt{Rd-mode} provides the ability to view and
596 execute code embedded in the help file in the same manner as ESS
597 handles code from any S language source file. It provides syntax
598 highlighting and the ability to submit code directly to a running ESS
599 process, either R or \Splus, for evaluation and debugging. This
600 latter feature is useful for ensuring that code developed using R runs
601 under \Splus.
603 \paragraph{Cooperation across Multiple Tools.}
604 Statistical packages are intended for either general statistical
605 analyses or for specialized forms of statistical analyses. The
606 specialized statistical packages can be far more efficient for their
607 intended activities, but this is balanced by their inability to
608 perform a wide range of general statistical functions. Tightly
609 coupled inter-operability between general and specialized packages
610 rarely exists, but such a facility is often desired. For example, a
611 general purpose package such as R does not perform Bayesian analyses
612 as easily as BUGS does. On the other hand, BUGS lacks breadth in the
613 range of analyses and results it can generate. For this reason, BUGS
614 is often distributed with R packages, like the diagnostic packages
615 CODA and BOA, which assist with importing and analyzing the results in
616 R. Another point of contention is the difference in the interfaces
617 between general packages and specialized packages. ESS helps by
618 providing a single point of contact to both tools, though the typical
619 interfaces (interactive for R, batch for BUGS) are different.
621 %\item[Rodney:] I can't speak for everyone, but the BUGS users I know are
622 % .. lots deleted by AJR
623 %will make sense. Besides, the most pressing need for me is to get
624 %ESS-elsewhere to work with ESS[BUGS] rather than creating inferior-BUGS.
626 %\item[Rich:] How does making ``ESS-elsewhere work with ESS[BUGS]'' differ
627 %from ``creating inferior-BUGS''? My question is predicated on the assumption
628 %that ESS-elsewhere is a (generalized) minor-mode that makes the location
629 %of the program irrelevant.
630 %See my ESS-elsewhere quibble below.
632 %\item[Rodney:] It's the whole batch BUGS vs. interactive BUGS thing. Batch
633 %BUGS with ESS-elsewhere; interactive BUGS with inferior-BUGS which does not
634 %and will never exist. If you want to call ``inferior-ESS'' ``ESS-elsewhere''
635 %why do you need two different names? ``inferior-ESS'' is a terrible name
636 %so the change would be fine with me, but you can't have it both ways? Is
637 %this why you keep saying that ESS-elsewhere works for SAS? See
638 %response to quibble below.
640 %\item[Rich:]
641 %\stexttt{iESS[SAS]} was designed to mimic as well as possible \stexttt{iESS[S]}.
642 %I need to read doc/README.SAS to make sure all of its options are represented
643 %here. --- Not yet done.
644 %\end{description}
645 %\end{Comment}
647 \paragraph{Simplifying Keymap Differences.}
648 Simple conflicts between interfaces are exemplified by different key
649 sequences for editing tasks such as cut, copy, paste, beginning of
650 line, end of line, etc. These may be the most aggravating because our
651 fingers are typing ``instinctively'', but differences in interfaces
652 circumvent this learned behavior. ESS solves this problem by
653 providing a uniform interface to keyboard actions across the variety
654 of statistical packages that might be used. That is, the same key
655 sequences are used for cursor movement, evaluation, and basic tasks
656 such as loading files for editing.
658 \paragraph{Concurrent Use of Multiple Machines and Operating Systems.}
659 It can be useful to have multiple statistical processes running
660 simultaneously, either on a single machine or a variety of machines.
661 This capability assists with large-scale numerical simulations as well
662 as code design and testing across multiple versions of statistical
663 software packages.
665 \subsection{Interactive Processing.}
666 \label{sec:interactive}
668 The increased popularity of exploratory data analysis as well as the
669 advent of simple GUIs has made interactive data analysis an important
670 component to statistical practices.
671 ESS uses three different approaches for communicating with statistical
672 packages.
674 \paragraph{Inter-Process Communication.}
675 Packages that use the command-line interface are run as an inferior
676 process in an Emacs buffer, with the standard input and output of the
677 package redirected to the buffer. Packages that do not use the
678 command-line interface must be run as an independent process, possibly
679 with limited cooperation.
681 ESS can use the Windows DDE (Dynamic Data Exchange) protocol to
682 provide one-way communication directly to packages which function as a
683 DDE server. ESS can control the actions of the package, but it can not capture
684 the results directly. Transcripts must be physically copied to an
685 Emacs buffer to get the transcript editing features.
687 Statistical packages that use neither the standard input/standard
688 output protocol nor DDE can not be directly controlled by Emacs. But, ESS
689 can still provide an editing environment for these statistical languages. The
690 user must either manually cut and paste the edited code into the
691 package or save the edited files and run them in a batch environment.
692 The Microsoft Windows versions of \SAS, \Stata, and \XLispStat\ are
693 in this category.
695 One useful extension in ESS is relaxation of the requirement that the
696 statistics program be available on the local machine. ESS provides
697 both transparent editing of files and execution of statistics packages
698 on a remote machine with \stexttt{iESS[S]} or \stexttt{iESS[SAS]} (see
699 below). All the editing and interaction features described for the
700 local machine work equally well on the remote machine. The
701 interaction, including all the unique features of working with ESS,
702 appears to the user as if the program were running on the local
703 %rmh: The interaction ... appears ....
704 machine. If the X11 Windowing system is running on the local machine,
705 it is even possible to bring up visual displays and graphics from
706 remote Unix systems onto a local Microsoft Windows or Apple Mac
707 display.
709 \paragraph{Interactive S family}
710 ESS for S family statistical languages, \stexttt{iESS[S]},
711 replaces the \Splus\ Commands window or the R GUI window. In addition
712 to running the S family language process, \stexttt{iESS[S]} mode provides the
713 same editing features, including syntactic highlighting and
714 string-search, as the editing mode \stexttt{ESS[S]}. It also provides
715 an interactive history mechanism; transcript recording and editing;
716 and the ability to re-submit the contents of a multi-line command to
717 the executing process with a single keystroke. \stexttt{iESS[S]} is
718 used with S, \Splus, and R on Unix and with Sqpe and R on Windows.
720 The \Splus\ GUI on Windows can be a DDE server. There are two
721 advantages to using even this limited communication with the \Splus\
722 GUI through ESS. First, through \stexttt{ESS[S]} mode the user gets
723 the full editing capabilities of Emacs. Second, S language commands
724 % rmh: S, not \Splus, in both places. The {\it language} is S.
725 % The previous session could be R or ATT S. It is not restricted to \Splus.
726 are sent from the editing mode \stexttt{ESS[S]} buffer and from
727 transcript buffers from previous S sessions directly to the GUI
728 Commands window with the same Emacs key sequences as are used with ESS
729 on Unix. Hence the user can work in a powerful editing environment
730 and is protected from the delay and ergonomic challenges of using the
731 mouse for copy and paste operations across windows.
733 \paragraph{Interactive \SAS.}
734 \stexttt{iESS[SAS]} is a mode that allows text-based \stexttt{PROC} by
735 \stexttt{PROC} interaction with an inferior buffer running an
736 interactive \SAS\ session on either the local or a remote computer.
737 \stexttt{iESS[SAS]} mode works by redirecting standard input and
738 output from \SAS\ to ESS. Currently, the \stexttt{iESS[SAS]} mode can
739 run on any computer, but the \SAS\ process it is controlling must be
740 running on a Unix machine. This process is very efficient for dial-up
741 network connections to a remote computer with \SAS\ installed. The
742 resulting interface is similar to the SAS character terminal
743 interface, but with Emacs key sequences.
745 %Rodney: What is this paragraph about? I'm going to comment it out
746 %because I don't recognize what it is supposed to be. Maybe somebody
747 %can fix it later.
749 % rmh: Round umpteen. Yes, this is redundant with the third paragraph
750 % of interprocess communication. I still want it here. Try this rephrasing.
752 \stexttt{ESS[SAS]} mode can be used in conjunction with the \SAS\
753 Display Manager to allow simultaneous access to Emacs for editing
754 \SAS\ language code and to the \SAS\ mouse-based interfaces to the
755 graphical routines and help system.
757 %%%%% AJR: WHY IS THIS SUBSTANTIALLY DIFFERENT THAN BATCH? I KNOW ITS
758 %%%%% SLIGHTLY DIFFERENT, BUT SUBSTANTIALLY?
759 %%%%% rmh: this is a form of interaction, not batch. I restored the
760 %%%%% first paragraph with some expansion.
761 %\paragraph{\SAS---Interactive cooperation with the \SAS\ Display Manager.}
762 %ESS users who write data analysis code in \stexttt{ESS[SAS]} mode in Emacs
763 %often need to work with the \SAS\ Display Manager's
764 %mouse-based interface to the graphical
765 %routines, the help system, and other non-text-based features.
766 %%The authors of ESS prefer the Emacs environment for
767 %%the text-file interaction with \SAS, that is with editing and
768 %%managing input command files and output listing and log files,
769 %%even on computer systems which run
770 %%the \SAS\ Display Manager environment.
771 %In this situation, the user
772 %designs the command file in \stexttt{ESS[SAS]} mode and highlights
773 %regions to be forwarded to \SAS\ for processing.
775 %% Rodney: I don't see this as a feature of either ESS or emacs. And,
776 %% what the authors prefer is certainly not germane.
779 %% rmh: This is my preferred mode for interacting with SAS. I tried another
780 %% rephrasing. It {\it is} a feature of ESS. ESS is able to provide ESS[SAS]
781 %% mode for the text processing (.sas .lst. log files) and simultaneously
782 %% let the user have interactive graphical access.
783 %%This can be done by either:
784 %%\begin{enumerate}
785 %%\item copying and pasting the marked regions to the \SAS\ Editor window
786 %% and then pressing the \stexttt{RUN} button. Highlighted sections of
787 %% the \SAS\ Listing window are brought back to Emacs to be read in the
788 %% \stexttt{ESSlst} mode editing environment.
789 %%\item submitting the marked region for Batch File Processing (see the
790 %% next section) but using the mapped key sequences to append to the log
791 %% and listing files instead of replacing them.
792 %%\end{enumerate}
794 \subsection{Batch File Processing.}
795 \label{sec:batch-file}
797 Batch file processing with statistical analysis packages is a better
798 choice than interactive processing when the execution times are longer
799 than the user is willing to wait as well as for regularly updated
800 statistical reports and figures. ESS provides a means to shorten the
801 debugging cycle for writing code intended for batch evaluation by
802 containing the whole process, both writing and evaluation, within
803 Emacs.
805 \paragraph{Batch \SAS.}
806 \label{sec:sas-batch}
808 \SAS\ is a popular choice for processing and analyzing large amounts
809 of data. However, interactive \SAS\ is rarely used in these situations
810 due to the length of time involved. Instead, a file containing \SAS\
811 commands is created and \SAS\ executes these commands in the background,
812 or batch, while the user moves on to other activities.
814 ESS facilitates \SAS\ batch with \stexttt{ESS[SAS]}, the mode for files
815 with the \stexttt{sas} extension. ESS defines \SAS\ syntax so that
816 \stexttt{font-lock-mode} can highlight statements, procedures,
817 functions, macros, datasets, comments and character string literals in
818 \SAS\ programs. Optionally, the same language features are
819 highlighted in the \SAS\ log with the addition of log notes, warnings
820 and error messages.
822 For files with the \stexttt{sas} extension, ESS binds the function
823 keys in \stexttt{ESS[SAS]} mode to match the definitions used by \SAS\
824 Display Manager. These definitions are optionally available in all
825 modes. They are particularly useful when viewing \SAS\ log and
826 listing files (with extensions of \stexttt{log} and \stexttt{lst}
827 respectively).
829 Only one function key press is needed to submit a \SAS\ batch process.
830 Other function keys open the \SAS\ program, the \SAS\ log and the
831 \SAS\ listing buffers. When accessed in this manner, the \SAS\ log
832 and \SAS\ listing buffers are automatically updated since they may
833 have been appended or over-written by the \SAS\ batch process. In
834 addition, the \SAS\ log is searched for error messages and the error
835 messages, if any, are sequentially displayed with consecutive key
836 presses.
838 Another function key opens a \SAS\ permanent dataset for editing or
839 viewing. An option is provided so that the tab and return keys
840 operate in typewriter fashion like they do in \SAS\ Display Manager.
841 This option also defines a key to move the cursor to a previous
842 tab-stop and delete any characters between its present position and
843 the tab-stop. This is a \SAS\ Display Manager feature that is not
844 typically available in Emacs.
846 The \SAS\ batch process runs on the computer where the \SAS\ program
847 resides. This is important because any \SAS\ permanent datasets
848 referenced in a \SAS\ program only exist on the computer running \SAS.
849 If the \SAS\ program resides on a remote computer, then the
850 log and listing are also accessed remotely. The net result is that
851 running \SAS\ batch on remote computers is nearly transparent to the
852 ESS user.
854 %\begin{Comment}
855 %Rich's version:
856 %\end{Comment}
857 %The \SAS\ batch process can run on the same computer on which the
858 %emacs session is running or it can run on a remote computer. For
859 %remote jobs, files are transparently saved (with ftp or scp or kermit)
860 %and the batch process is transparently submitted through a telnet or
861 %ssh connection.
863 %\begin{Comment}
864 %Rich: I have some terminology quibbles here with how the term
865 %``ESS-elsewhere'' is used with SAS BATCH. I think of S-elsewhere or
866 %ESS-elsewhere as a trick to make a \stexttt{telnet-mode} buffer think
867 %it is \stexttt{iESS-mode} buffer.
869 %I don't think of file saving, editing, and retrieval as an example
870 %of ESS-elsewhere. Neither is submission of the remote job;
871 %that is just an ordinary shell command in an ordinary shell buffer.
872 %M-x SAS probably is an example of ESS-elsewhere, but I
873 %designed it before I thought of the ESS-elsewhere concept.
875 %The initial idea behind S-elsewhere was to run an interactive S or S-Plus
876 %session on a remote computer in telnet (or equivalent) buffer. The trick
877 %was to make the \stexttt{telnet-mode} buffer accept C-c C-n and
878 %related commands from the \stexttt{S-mode} buffers. Hence I had to
879 %make the \stexttt{telnet-mode} buffer think it is \stexttt{iESS-mode}
880 %buffer. The ``elsewhere'' part of the name is entirely related to a
881 %different start up procedure. Once the connection is made, there is
882 %{\em no} difference visible to the user. The buffer shows itself to
883 %be an ordinary \stexttt{iESS} buffer. Tony generalized S-elsewhere
884 %to ESS-elsewhere to allow other languages than S to be used
885 %interactively.
887 %I have been using ESS for SAS remote BATCH for years, ever since you
888 %and I started working on this together. We initially defined
889 %ess-sas-submit-method to encapsulate the location of the sas process.
890 %Except for a few lines of elisp to get the connection started, the user
891 %behavior has been identical whether the SAS process is on the same or
892 %different machine. Since we are not interactively talking to the SAS
893 %process in an inferior-ESS buffer I don't see this as ESS-elsewhere.
895 %Rodney: Remote submissions of SAS batch jobs never worked. I only got
896 %it to work a couple of weeks ago. The problem was with the cd command.
897 %You need to ignore the beginning and end of the expanded buffer name
898 %that are the ange-ftp/EFS/tramp stubs which tell Emacs what the remote
899 %username and hostname are. I find the batch usage of ESS-elsewhere
900 %entirely consistent with the interactive behavior. OTOH, I don't find
901 %the terminology particularly illuminating. I think ESS-remote or
902 %ESS-net would be more meaningful.
903 %\end{Comment}
905 \paragraph{Batch BUGS.}
906 BUGS software performs Markov Chain Monte Carlo integration. There is
907 an interactive capability, but it is not often used since the analyses
908 can be very time-consuming. Most BUGS programs are executed as batch
909 processes. ESS facilitates BUGS batch with \stexttt{ESS[BUGS]}, the
910 mode for files with the \stexttt{bug} extension. ESS provides 4
911 features. First, BUGS syntax is described to allow for proper
912 fontification of statements, distributions, functions, commands and
913 comments in BUGS model files, command files and log files. Second,
914 ESS creates templates for the command file from the model file so that
915 a BUGS batch process can be defined by a single file. Third, ESS
916 provides a BUGS batch script that allows ESS to set BUGS batch
917 parameters. Finally, key sequences are defined to create a command
918 file and submit a BUGS batch process.
920 \paragraph{Batch S family.}
921 ESS provides 2 facilities for batch processing of S family language files.
922 The first is to execute the contents of a file using buffer-evaluation. This
923 differs from interactive processing only by the number of commands
924 being evaluated; errors can be found by examining the resulting
925 transcript. The second is the load-source mechanism, which provides a
926 means of jumping to errors in the source file, but doesn't display the
927 evaluated commands in the transcript. These mechanisms provide
928 different tools for debugging the source files.
930 \section{History of ESS}
931 \label{sec:ESS:history}
933 ESS is built on Emacs, the editing system for which Richard Stallman
934 won a MacArthur Foundation Fellowship in 1990. Emacs has a long
935 history of being a programmer's editor. Many statisticians got their
936 first taste of the power of Emacs with \Fortran\ mode which was
937 introduced in 1986. As statisticians' preferences changed from
938 generalist compiled languages such as \Fortran\ to specialist
939 statistical analysis packages like S and \SAS, Emacs modes soon
940 followed.
942 The ESS environment is built on the open-source projects of
943 many contributors, dating back over 10 years.
944 Doug Bates and Ed Kademan wrote S-mode in 1989 to edit S and \Splus\
945 files in GNU Emacs. Frank Ritter and Mike Meyer added features,
946 creating version 2. Meyer and David Smith made further contributions,
947 creating version 3. For version 4, David Smith provided significant
948 enhancements to allow for powerful process interaction.
950 John Sall wrote GNU Emacs macros for \SAS\ source code around 1990.
951 Tom Cook added functions to submit jobs, review listing and log files,
952 and produce basic views of a dataset, thus creating a SAS-mode which was
953 distributed in 1994.
955 In 1994, A.J. Rossini extended S-mode to support XEmacs. Together
956 with extensions written by Martin M{\"a}chler, this became version
957 4.7 and supported S, \Splus, and R.
958 In 1995, Rossini extended SAS-mode to work with XEmacs.
960 In 1997, Rossini merged S-mode and SAS-mode into a single Emacs
961 package for statistical programming; the product of this marriage was
962 called ESS version 5. Richard M. Heiberger designed the inferior mode
963 for interactive \SAS\ and SAS-mode was further integrated into ESS.
964 Thomas Lumley's Stata mode, written around 1996, was also folded into
965 ESS. More changes were made to support additional statistical
966 languages, particularly \XLispStat.
968 ESS initially worked only with Unix statistics packages that used
969 standard-input and standard-output for both the command-line interface
970 and batch processing. ESS could not communicate with statistical
971 packages that did not use this protocol. This changed in 1998 when
972 Brian Ripley demonstrated use of the Windows Dynamic Data Exchange
973 (DDE) protocol with ESS. Heiberger then used DDE to provide
974 interactive interfaces for Windows versions of \Splus. In 1999,
975 Rodney A. Sparapani and Heiberger implemented \SAS\ batch for ESS, which
976 relies on files rather than standard-input/standard-output, on Unix,
977 Windows and Mac. In 2001, Sparapani added BUGS batch file processing
978 to ESS for Unix and Windows.
980 This history is summarized in Table \ref{tab:timeline}.
982 \begin{table}[tbp]
983 \centering
984 {\scriptsize
985 \begin{tabular}{c ll c ll}
986 \hline
987 Year \\
988 \hline
989 & \multicolumn{2}{c}{S-mode} && \multicolumn{2}{c}{SAS-mode} \\
990 \cline{2-3} \cline{5-6}
991 1989 & v.1 & (GNU Emacs, Unix, S/S+) && \\
992 1990 & & && & (GNU Emacs, Unix, SAS editing) \\
993 1991 & v.2 & (GNU Emacs, Unix, S/S+) && \\
994 1993 & v.3 & (GNU Emacs, Unix, S/S+) && \\
995 1994 & v.4 & (GNU Emacs/XEmacs, Unix, S/S+) && v.1 & (GNU Emacs, Unix, SAS batch) \\
996 1995 & v.4.7 & (GNU Emacs/XEmacs, Unix, S/S+/R) && v.2 & (GNU Emacs/XEmacs, Unix, SAS batch) \\
997 \cline{2-6}\\[-3.5ex]
998 \cline{2-6}
999 & \multicolumn{5}{c}{Emacs Speaks Statistics (ESS)} \\
1000 \cline{2-6}
1001 &\multicolumn{2}{c}{Emacs, Operating Systems} &&\multicolumn{2}{c}{Additional Functionality}\\
1002 \cline{2-3} \cline{5-6}
1003 1997 & v.5.0 & (GNU Emacs/XEmacs, Unix) &&& Stata, XLispStat, SAS interactive \\
1004 1998 & v.5.1.1 & (GNU Emacs/XEmacs, Unix/Windows) &&& S+elsewhere; Windows: S+/R\\
1005 1999 & v.5.1.10 & (GNU Emacs/XEmacs, Unix/Windows/Mac) &&& SAS batch; Omegahat \\
1006 2001 & v.5.1.19 & (GNU Emacs/XEmacs, Unix/Windows/Mac) &&& Unix/DOS: BUGS batch; Mac: R \\
1007 %% 2002 & v.5.1.20 & (Emacs/XEmacs, Unix/Windows/Mac) &&& Unix/DOS: BUGS batch, Mac: R \\
1008 %% 2002 & v.5.2 & (Emacs/XEmacs, Unix/Windows/Mac) &&& ? \\
1009 \hline
1010 \end{tabular}
1012 \caption{History and Ancestors of ESS}
1013 \label{tab:timeline}
1014 \end{table}
1017 %\section{Future Work}
1019 %%%There are two active areas of extensions for user environments. One
1020 %%%is to enhance the capabilities of the IDE for statistical practice;
1021 %%%this includes implementing such common IDE features as object
1022 %%%browsers, tool-tips, and interfacing cleaning. The other is to target
1023 %%%appropriate potentially useful programming methodologies for transfer
1024 %%%to statistical practice.
1026 %%%Literate Programming methodologies \citep{Knuth:1992,NRamsey:1994} are
1027 %%%a natural fit for statistical practice. We refer to the application
1028 %%%to statistical analysis as Literate Statistical Practice
1029 %%%\citep{rossini:dsc:2001}. The tools used are Noweb
1030 %%%\citep{NRamsey:1994} and either \LaTeX, \textsc{html}, or \textsc{xml}
1031 %%%for documenting and explaining the analysis. This approach to
1032 %%%programming encourages the use of a literary documentation style to
1033 %%%explain the programming code for the data analysis. The program can
1034 %%%then be extracted from the documentation text for realizing the
1035 %%%statistical analysis.
1037 %%future enhancement perhaps
1038 %%ESS provides the same ESS-elsewhere support for BUGS batch
1039 %%that it does for \SAS\ batch (see above).
1041 %Important extensions which should be implemented in future
1042 %versions include class browsers, analysis templates, tool-tips, and
1043 %similar features. Class browsers can be thought of as a tree or
1044 %outline for presenting datasets, variables and functions in the
1045 %context of what they represent; this allows for rapid and appropriate
1046 %inspection. Analysis templates would allow statistics centers and
1047 %groups to provide standardized templates for initiating an analysis.
1049 %Additional statistical packages can easily be added to ESS.
1051 %%While most IDE features have been developed for object-oriented
1052 %%languages, the above also can apply to non-object oriented
1053 %%programming.
1055 %ESS is one of the first Rapid Application Development (RAD)
1056 %environments intended for statisticians. It provides
1059 \section{Conclusion}
1060 \label{sec:concl}
1062 ESS provides an enhanced, powerful interface for efficient interactive
1063 data analysis and statistical programming. It allows the user
1064 complete control over the communications among the files in which the
1065 analysis is specified, the statistical process doing the computation,
1066 and the output. Because all are within the same programming
1067 environment, and therefore are accessed with the same editing and
1068 searching concepts and the same key sequences, user efficiency is
1069 increased. It is completely customizable to satisfy individual
1070 desires for interface styles and can be extended to support other
1071 statistical languages and data analysis packages.
1073 %\begin{Comment}
1074 %Rich: see my discussion of ESS-elsewhere terminology.
1076 %What is the behavior for remote SAS that is new for 2002?
1078 %Rodney: SAS batch now works and Kermit was added as a method of transfer.
1079 %\end{Comment}
1080 %ESS-elsewhere provides interactive and batch processing
1081 %with \SAS\ running on a remote machine that is accessed over a
1082 %network. This provides a powerful development environment for \SAS.
1084 %%This
1085 %%includes support for syntax highlighting and template-based source file
1086 %%generation that provides the capability of specifying all the necessary
1087 %%parameters for a BUGS batch run in a single file.
1089 \bibliographystyle{plainnat}
1090 \pdfbookmark[1]{References}{section.7}
1091 %\addcontentsline {toc}{section}{\numberline {}References}
1092 \bibliography{ess-intro-graphs}
1094 \clearpage
1096 \appendix
1097 \section{Appendix: ESS Resources on the Internet}
1098 %\addcontentsline {toc}{section}{\numberline {}ESS Resources on the Internet}
1099 \label{sec:access}
1101 \paragraph{Latest Version.}
1103 ESS is constantly in flux. New versions of statistical
1104 packages, Emacs and operating systems require new releases of ESS to
1105 support them. The latest stable version of ESS can be found on the web at
1106 \url{http://www.analytics.washington.edu/downloads/ess/}. To get help
1107 with problems, send e-mail to \url{mailto: ess-help@stat.math.ethz.ch}.
1108 The latest development, hence unstable, version can be obtained by
1109 anonymous CVS. First type:
1111 \stexttt{cvs -d
1112 :pserver:anoncvs@cvs.analytics.washington.edu:/var/anoncvs login}
1114 You will be prompted for a password which is ``\stexttt{anoncvs}''.
1115 Then type:
1117 \stexttt{cvs -d
1118 :pserver:anoncvs@cvs.analytics.washington.edu:/var/anoncvs co
1119 ess}
1121 \paragraph{Additional documentation.}
1123 An expanded version of the present paper is in \citep{RMHHS:2001}. A
1124 general introduction and usage instructions can be found in
1125 \citep{heiberger:dsc:2001}; in addition, one which is more focused on
1126 \SAS\ can be found in \citep{heiberger:philasugi:2001}. The
1127 documentation that comes with ESS provides details of its
1128 implementation as well as examples of its use.
1130 \end{document}
1133 %%% Local Variables:
1134 %%% mode: latex
1135 %%% TeX-master: t
1136 %%% End: