Skip to content
forked from emacs-ess/ESS

Commit

Permalink
Merge branch 'trunk'
Browse files Browse the repository at this point in the history
  • Loading branch information
vspinu committed Jan 21, 2013
2 parents 2473cf4 + 2b9d8aa commit de82413
Show file tree
Hide file tree
Showing 18 changed files with 384 additions and 166 deletions.
12 changes: 12 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
2013-01-14 Rodney Sparapani <rsparapa@mcw.edu>

* Makeconf (INFODIR): on Mac OS X, this
directory does not fall under Emacs.app as
previously indicated; it is actually the
same as you might expect on UNIX/Linux,
i.e. /usr/local/info

2013-01-12 ESS Maintainers <ESS-core@r-project.org>

* Version 12.09-2 released.

2012-12-21 ESS Maintainers <ESS-core@r-project.org>

* Version 12.09-1 released.
Expand Down
2 changes: 1 addition & 1 deletion Makeconf
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ ETCDIR =$(PREFIX)/share/emacs/etc/ess
#PREFIX=/Applications/Emacs.app/Contents/Resources
#EMACS=/Applications/Emacs.app/Contents/MacOS/Emacs
#LISPDIR=$(PREFIX)/site-lisp/ess
#INFODIR=$(PREFIX)/info
#INFODIR=/usr/local/info
#ETCDIR =$(PREFIX)/etc/ess
#

Expand Down
6 changes: 6 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
ess (12.09-2-1) unstable; urgency=low

* New upstream version released today

-- Dirk Eddelbuettel <edd@debian.org> Sat, 12 Jan 2013 15:51:47 -0600

ess (12.09-1-1) unstable; urgency=low

* New upstream version released twelve hours ago
Expand Down
2 changes: 1 addition & 1 deletion doc/currfeat.texi
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
@item SAS
@item OpenBUGS/JAGS
@item Stata
@item XLispStat including Arc and ViSta
@c @item XLispStat including Arc and ViSta
@item Julia
@end itemize
@item Editing source code (S family, SAS, OpenBUGS/JAGS, Stata, Julia)
Expand Down
41 changes: 17 additions & 24 deletions doc/ess.texi
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ ESS @w{version @ESSVER}

@dircategory Emacs
@direntry
* ESS: (ess). Emacs Speaks Statistics (S/S+/R, SAS, BUGS/JAGS, Stata, XLisp-Stat).
* ESS: (ess). Emacs Speaks Statistics (S/S+/R, SAS, BUGS/JAGS and Stata).
@end direntry
@c node-name, next, previous, up
@node Top, Introduction, (dir), (dir)
Expand Down Expand Up @@ -128,7 +128,7 @@ S family and SAS respectively. Later on, Stata-mode was also incorporated.

ESS provides a common, generic, and useful interface, through emacs, to
many statistical packages. It currently supports the S family, SAS, BUGS/JAGS,
Stata and XLisp-Stat with the level of support roughly in that order.
and Stata with the level of support roughly in that order.

A bit of notation before we begin. @emph{emacs} refers to both
@emph{GNU Emacs} by the Free Software Foundation, as well as
Expand All @@ -142,7 +142,7 @@ mode @code{ESS[language]}, where @code{language} can take values such as

Currently, the documentation contains many references to @cite{`S'}
where actually any supported (statistics) language is meant, i.e., `S'
could also mean `XLisp-Stat' or `SAS'.
could also mean `R' or `SAS'.

@cindex interactive use of S

Expand Down Expand Up @@ -210,7 +210,7 @@ package which is waiting for you to input commands). These include:
@b{Command-line editing} for fixing mistakes in commands before they are
entered. The @samp{-e} flag for S-plus provides something similar to
this, but here you have the full range of Emacs commands rather than a
limited subset. However, other packages such as XLisp-Stat and S3 do not
limited subset. However, other packages do not
necessarily have features like this built-in.
@xref{Command-line editing}.

Expand Down Expand Up @@ -1136,7 +1136,7 @@ or will only want one global command history file and have
@smallexample
(setq ess-history-directory "~/.R/")
@end smallexample
in there @file{.emacs} file.
in your @file{.emacs} file.

@comment node-name, next, previous, up
@node History expansion, Hot keys, Command History, Entering commands
Expand Down Expand Up @@ -1763,7 +1763,7 @@ the appropriate place as well. Lines which continue an incomplete
expression are indented relative to the first line of the expression.
Function definitions, @code{if} statements, calls to @code{expression()}
and loop constructs are all recognized and indented appropriately. User
variables are provided to control the amount if indentation in each
variables are provided to control the amount of indentation in each
case, and there are also a number of predefined indentation styles to
choose from.

Expand Down Expand Up @@ -1799,7 +1799,7 @@ indented by the same amount (but relative indents are preserved).

@item
@kbd{RET} (@code{newline-and-indent}) @*
@kbd{LFD} (@emph{newline-and-indent}) @*
@kbd{LFD} (@code{newline-and-indent}) @*
Insert a newline, and indent the next line. (Note that most keyboards
nowadays do not have a @key{LINEFEED} key, but @kbd{C-j} is equivalent.)

Expand Down Expand Up @@ -2467,8 +2467,8 @@ whatever reason.
@pindex ac-source-R
@pindex ac-source-R-args
@pindex ac-source-R-objects
ESS provides three sources for @code{Auto Completion} mode
(@uref{http://cx4a.org/software/auto-complete/}) -
ESS provides three sources for @code{Auto Completion} mode:
@comment (@uref{http://cx4a.org/software/auto-complete/})
@code{ac-source-R-args}, @code{ac-source-R-objects} and
@code{ac-source-R}. The last one combines the previous two and makes them
play nicely together. See auto-complete package documentation
Expand Down Expand Up @@ -2528,9 +2528,9 @@ packages:
@section ESS tracebug
@cindex ESS tracebug
@pindex ess-tracebug
@emph{Note:} The official ess-tracebug documentation is still at
@uref{http://code.google.com/p/ess-tracebug/}, and is currently being
moved into this manual.
@emph{Note:} The official ess-tracebug documentation is at
@uref{http://code.google.com/p/ess-tracebug/}, but it is in the process of
being moved into this manual.

ESS @code{tracebug} package offers visual debugging, interactive error
navigation, interactive backtrace, breakpoint manipulation, control over
Expand Down Expand Up @@ -2612,8 +2612,8 @@ C-p . Goto previous BP . `ess-bp-previous'
* Input Ring:
i . Goto input event marker forwards . `ess-dbg-goto-input-event-marker'
I . Goto input event marker backwards . `ess-dbg-goto-input-event-marker'
i . Goto input event marker forwards . `ess-dbg-goto-input-event-marker'
I . Goto input event marker backwards . `ess-dbg-goto-input-event-marker'
* Misc:
? . Show this help . `ess-tracebug-show-help'
Expand Down Expand Up @@ -2904,7 +2904,7 @@ and functions defined in .GlobalEnv can see the objects in
@uref{http://cran.r-project.org/doc/manuals/R-ints.html#Namespaces}.

In order to use ess-developer mode add names of the packages you are
developing to @code{ess-developer-packages}. You can do taht interactively
developing to @code{ess-developer-packages}. You can do that interactively
with @kbd{C-c C-t a}, and remove packages with @kbd{C-c C-t r}. When
developer mode is on, the name of the process in the mode line is
highlighted with @code{ess-developer-indicator-face}.
Expand All @@ -2923,12 +2923,12 @@ When developer mode is on, ESS evaluation commands behave differently:

@item @kbd{C-c C-l} (@code{ess-load-file}) asks for the package to source
into and inserts all redefined objects into the package:foo or
name space:foo accordingly:
namespace:foo accordingly

@itemize @minus

@item PLAIN OBJECTS and FUNCTIONS: @*
If the object is found in an environment (packag:foo or namespace:foo),
If the object is found in an environment (package:foo or namespace:foo),
and differs from the old one it is assigned into the corresponding
environment. If the object is not found it is assigned into
.GlobalEnv. The environment of functions is set to namespace:foo.
Expand Down Expand Up @@ -3288,13 +3288,6 @@ plotting objects in your current R session. If you are used to using
the dired (directory editor) facility in Emacs, this mode gives you
similar functionality for R objects.

To get started, first make sure you can load ess-rdired. Add the
following to your .emacs and then restart emacs.
@example
(autoload 'ess-rdired "ess-rdired"
"View *R* objects in a dired-like buffer." t)
@end example

Start an R session with @kbd{M-x R} and then store a few
variables, such as:

Expand Down
26 changes: 26 additions & 0 deletions doc/newfeat.texi
Original file line number Diff line number Diff line change
@@ -1,5 +1,31 @@
@itemize @w{}

Changes/Bug Fixes in 12.09-2:
@itemize @bullet
@item @ESS{}: new @code{ess-switch-to-end-of-proc-buffer} variable that controls
whether @kbd{C-c C-z} switches to the end of process buffer. The
default is @code{t}. You can use prefix argument to @kbd{C-c C-z} to
toggle this variable.
@item @ESS{}: fix in @code{ess-eval-linewise} that was causing emacs
to hang during R debugging with @code{ess-eval-visibly} equal to
@code{t}.
@item @ESS{}: fix in @code{ess-eval-linewise} that was causing emacs to recenter
the prompt in visible window
@item @ESS{[tracebug]}: A better handling of ``Selection'' prompts
and debug related singlekey commands.
@item @ESS{}: fix a bug in @code{ess-switch-process} that was causing
@code{*new*} selection to fail.
@item @ESS{[R]}: Solve missing @code{ess-local-process-name} bug in R-dired.
@item @ESS{[SWV]}: @code{ess-swv-PDF} doesn't ask for a command to run if
there is only one command in @code{ess-swv-pdflatex-commands}.
@item @ESS{[SWV]}: @code{ess-swv-weave} gained an universal argument to
allow for an interactive choice between available weavers (sweave,
knitr).
@item @ESS{}: @code{ess-eval-*-and-step} functions go to next empty
line at eob, instead of staying at the last line.
@end itemize


Changes/New Features in 12.09-1:
@itemize @bullet
@item @ESS{} @emph{Breaking Changes in Keys}:
Expand Down
2 changes: 1 addition & 1 deletion doc/readme.texi
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ This is the README file for the distribution of ESS version

ESS is a GNU Emacs and XEmacs mode for interactive statistical
programming and data analysis. Languages supported: the S family (S,
S-PLUS and R), SAS, BUGS/JAGS, Stata and XLispStat. ESS grew out of the
S-PLUS and R), SAS, BUGS/JAGS and Stata. ESS grew out of the
desire for bug fixes and extensions to S-mode and SAS-mode as well as a
consistent union of their features in one package.

Expand Down
14 changes: 7 additions & 7 deletions doc/windows.texi
Original file line number Diff line number Diff line change
Expand Up @@ -250,11 +250,11 @@ If you wish to run R, you can start it with:
M-x R
@end example

XLispStat can not currently be run with
@example
M-x XLS
@end example
Hopefully, this will change. However, you can still edit with
emacs, and cut and paste the results into the XLispStat
*Listener* Window under Microsoft Windows.
@c XLispStat can not currently be run with
@c @example
@c M-x XLS
@c @end example
@c Hopefully, this will change. However, you can still edit with
@c emacs, and cut and paste the results into the XLispStat
@c *Listener* Window under Microsoft Windows.

122 changes: 122 additions & 0 deletions etc/C-cC-c-probl.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
foobar <- function(...) {}
rm(list=ls())

##--------> consequence of the above experiments:
## the 2nd form is numerically "uniformly better" than the first
##--------> 2011-05-27: Change Frank's psiInv() to
## psiInv = function(t,theta)
## -log1p(exp(-theta)*expm1((1-t)*theta)/expm1(-theta))

##--- In the following block, in the first line, C-c C-c did *NOT* behave

th <- 48 # now do ls() and see what happened ... the horror !!!
d <- 3
cpF <- list("Frank", list(th, 1:d))
cop <- acF <- cpF$copula


### Here, the bug (12.09-2, e.g.) has been that
### the function beginning is not found reliably:
### C-M-q -> should go to end; then C-M-a should go back to beginning (here)
mplot4 <- function(x, vList, xvar, cvar, rvar, log = "",
verbose=FALSE, show.layout=verbose)
{
dn <- dimnames(x)
## the variable displayed in one plot (with different colors):
v <- setdiff(names(dn), c(xvar, cvar, rvar))
stopifnot(length(v) == 1, 1 <= (nv <- length(dn[[v]])), nv <= length(pcol),
length(pspc) == 2, length(spc) == 2, length(axlabspc) == 2,
length(labspc) == 2, length(auxcol) == 4)
v.col <- colorRampPalette(pcol, space="Lab")(nv) # colors for v
## permute to know the component indices:
x <- aperm(x, perm=c(rvar, cvar, v, xvar))

if(is.null(xlab)) # default: the expression from varlist
xlab <- vList[[xvar]]$expr
z <- as.numeric(vList[[xvar]]$value) # pick out different x values
zrange <- range(z) # for forcing the same x axis limits per row

## set up the grid layout
nx <- length(dn[[cvar]]) # number of plot columns
nx. <- nx+1+(nx-1)+1 # +1: for y axis label; +(nx-1): for gaps; +1: for row labels
ny <- length(dn[[rvar]]) # number of plot rows
ny. <- ny+1+(ny-1)+1 # +1: for column labels; +(ny-1): for gaps; +1: for x axis label
## plot settings, restored on exit
opar <- par(no.readonly=TRUE); on.exit(par(opar))
plot.new() # start (empty) new page with 'graphics'
gl <- grid.layout(nx., ny.,
## units in npc as for pdf(); no square plotting region otherwise:
default.units="npc",
widths=c(axlabspc[1], rep(c(pspc[1], spc[1]), nx-1), pspc[1], labspc[1]),
heights=c(labspc[2], rep(c(pspc[2], spc[2]), ny-1), pspc[2], axlabspc[2]))
if(show.layout) grid.show.layout(gl, vp=viewport(width=1.25, height=1.25))
pushViewport(viewport(layout=gl)) # use this layout in a viewport

## --- plot data ---
for(i in 1:nx) { # rows
i. <- 2*i # column index in layout (for jumping over gaps)
if(verbose) cat(sprintf("plot row %d (%d): [columns:] ", i, i.))
yrange <- range(x[i,,,]) # for forcing the same y axis limits per row
for(j in 1:ny) { # columns
j. <- 2*j # row index in layout (for jumping over gaps)
if(verbose) cat(sprintf("%d (%d) ", j, j.))
pushViewport(viewport(layout.pos.row=i., layout.pos.col=j.))

## plot
grid.rect(gp=gpar(col=NA, fill=auxcol[3])) # background
## start a 'graphics' plot
par(plt = gridPLT())
## Hmm, this is not really useful for debugging:
## rp <- tryCatch(par(plt=gridPLT()), error = function(e)e)
## if(inherits(rp, "error")) {
## cat("\n *** ERROR in mplot() :\n", rp$message,"\n"); return(gl)
## }
par(new=TRUE) # always do this before each new 'graphics' plot
## set up coordinate axes:
plot(zrange, yrange, log=log, type="n", ann=FALSE, axes=FALSE)
## background grid:
grid(col=auxcol[4], lty="solid", lwd=grid.lwd, equilogs=FALSE)
## plot corresponding points/lines
for(k in 1:nv) points(z, x[i,j,k,], type="b", col=v.col[k])
## axes
c1 <- auxcol[1]
if(i == nx) # x axes
axis(1, lwd=ax.lwd, col=NA, col.ticks=c1, col.axis=c1)
if(j == 1) { # y axes
if(packageVersion("sfsmisc") >= "1.0-21")
## allow for adjusting colors of small ticks
eaxis(2, lwd=ax.lwd, col=NA, col.ticks=c1, col.axis=c1,
small.args=list(col=NA, col.ticks=c1, col.axis=c1))
else
eaxis(2, lwd=ax.lwd, col=NA, col.ticks=c1, col.axis=c1)
}
upViewport()

## column labels
if(i == 1) {
pushViewport(viewport(layout.pos.row=1, layout.pos.col=j.))
grid.rect(gp=gpar(col=NA, fill=auxcol[2]))
grid.text(parse(text=dn[[cvar]][j]), x=0.5, y=0.5, gp=gpar(cex=tx.cex))
upViewport()
}

## row labels
if(j == 2) {
pushViewport(viewport(layout.pos.row=i., layout.pos.col=nx.))
grid.rect(gp=gpar(col=NA, fill=auxcol[2]))
grid.text(parse(text=dn[[rvar]][i]), x=0.5, y=0.5, gp=gpar(cex=tx.cex), rot=-90)
upViewport()
}
}## for(j ..)
if(verbose) cat("\n")
}## for(i ..)

## legend
pushViewport(viewport(layout.pos.row=ny., layout.pos.col=2:(ny.-1)))
ll <- 0.01 # line length

## [... ... made example smaller ... ESS-bug still shows ....]

upViewport()
invisible(gl)
}
14 changes: 10 additions & 4 deletions lisp/ess-custom.el
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
:prefix "ess-")
;; Variables (not user-changeable)

(defvar ess-version "12.09-1" ;; updated by 'make'
(defvar ess-version "12.09-2" ;; updated by 'make'
"Version of ESS currently loaded.")

(defvar ess-revision nil ;; set
Expand Down Expand Up @@ -221,9 +221,9 @@ See also `tooltip-hide-delay' and `tooltip-delay'.

(defcustom ess-R-describe-object-at-point-commands
'(("str(%s)")
("summary(%s)")
("head(%s, n = 100)")
("tail(%s, n = 100)"))
("head(%s, n = 40)")
("tail(%s, n = 40)")
("summary(%s)"))
"A list of commands cycled by `ess-describe-object-at-point'.
%s is substituted with the name at point. The value of the
aliment is not used as yet and has no effect."
Expand Down Expand Up @@ -1023,8 +1023,14 @@ to sweave the current noweb file and latex the result."
(defvar ess-local-process-name nil
"The name of the ESS process associated with the current buffer.")
(put 'ess-local-process-name 'risky-local-variable t)
(put 'ess-local-process-name 'permanent-local t)
(make-variable-buffer-local 'ess-local-process-name)

(defcustom ess-switch-to-end-of-proc-buffer t
"If t, `ess-switch-to-inferior-or-script-buffer goes to end of
process buffer."
:group 'ess
:type 'boolean)

(defcustom ess-gen-proc-buffer-name-function 'ess-gen-proc-buffer-name:simple
"Function used for generation of the buffer name of the newly created ESS process.
Expand Down
Loading

0 comments on commit de82413

Please sign in to comment.