Initial commit.
This commit is contained in:
26
.emacs.d/elpa/ess-20160208.453/etc/BACKBUG5.BAT
Normal file
26
.emacs.d/elpa/ess-20160208.453/etc/BACKBUG5.BAT
Normal file
@@ -0,0 +1,26 @@
|
||||
@echo off
|
||||
rem ESS[BUGS]: 02/18/2004
|
||||
rem runs BUGS taking commands from command file
|
||||
|
||||
if not "%2"=="" goto 20
|
||||
if not "%1"=="" goto 10
|
||||
|
||||
echo usage: backbug5 [default_output_name] command_file
|
||||
goto 40
|
||||
|
||||
:10
|
||||
if exist bugs.bog attrib -r bugs.bog
|
||||
bugs05.exe bugs.buf bugs.bog bugs.out bugs.ind bugs1.out bugs1.ind %1
|
||||
copy /y bugs.log bugs.bog
|
||||
attrib +r bugs.bog
|
||||
goto 40
|
||||
|
||||
:20
|
||||
set one=1
|
||||
if exist %1.bog attrib -r %1.bog
|
||||
bugs05.exe %1.buf %1.bog %1.out %1.ind %1%one%.out %1%one%.ind %2
|
||||
copy /y %1.log %1.bog
|
||||
attrib +r %1.bog
|
||||
goto 40
|
||||
|
||||
:40
|
32
.emacs.d/elpa/ess-20160208.453/etc/BACKBUGS.BAT
Executable file
32
.emacs.d/elpa/ess-20160208.453/etc/BACKBUGS.BAT
Executable file
@@ -0,0 +1,32 @@
|
||||
@echo off
|
||||
rem ESS[BUGS]: 02/13/2003
|
||||
rem runs BUGS taking commands from command file
|
||||
|
||||
if not "%3"=="" goto 30
|
||||
if not "%2"=="" goto 20
|
||||
if not "%1"=="" goto 10
|
||||
|
||||
echo usage: backbugs [[number_of_bins] default_output_name] command_file
|
||||
goto 40
|
||||
|
||||
:10
|
||||
bugs0603.exe 32 bugs %1
|
||||
if exist bugs.bog attrib -r bugs.bog
|
||||
copy /y bugs.log bugs.bog
|
||||
attrib +r bugs.bog
|
||||
goto 40
|
||||
|
||||
:20
|
||||
bugs0603.exe 32 %1 %2
|
||||
if exist %1.bog attrib -r %1.bog
|
||||
copy /y %1.log %1.bog
|
||||
attrib +r %1.bog
|
||||
goto 40
|
||||
|
||||
:30
|
||||
bugs0603.exe %1 %2 %3
|
||||
if exist %2.bog attrib -r %2.bog
|
||||
copy /y %2.log %2.bog
|
||||
attrib +r %2.bog
|
||||
|
||||
:40
|
122
.emacs.d/elpa/ess-20160208.453/etc/C-cC-c-probl.R
Normal file
122
.emacs.d/elpa/ess-20160208.453/etc/C-cC-c-probl.R
Normal file
@@ -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)
|
||||
}
|
18
.emacs.d/elpa/ess-20160208.453/etc/ESSR/BUILDESSR
Executable file
18
.emacs.d/elpa/ess-20160208.453/etc/ESSR/BUILDESSR
Executable file
@@ -0,0 +1,18 @@
|
||||
#!/usr/bin/Rscript
|
||||
## -*- mode: R -*-
|
||||
## code to build ESSR environemnt.
|
||||
## Assume that current directory is etc/ESSR
|
||||
## run "./BUILDESSR destdir" to create ESSR_<version>.rda in destdir
|
||||
## where <version> is picked form ./VERSION file
|
||||
|
||||
|
||||
args <- commandArgs(TRUE)
|
||||
dir <- if(length(args)) args[[1]] else "."
|
||||
ver <- scan("./VERSION", what = "character", quiet = TRUE)
|
||||
rda_file <- sprintf("%s/ESSR_%s.rda", dir, ver)
|
||||
|
||||
## exactly as in ess--R-load-ESSR in ess-r-d.el
|
||||
source('./R/.load.R', local=TRUE)
|
||||
ESSR <- load.ESSR('./R/')
|
||||
|
||||
save(ESSR, file = rda_file)
|
23
.emacs.d/elpa/ess-20160208.453/etc/ESSR/LOADREMOTE
Normal file
23
.emacs.d/elpa/ess-20160208.453/etc/ESSR/LOADREMOTE
Normal file
@@ -0,0 +1,23 @@
|
||||
## -*- mode: R -*-
|
||||
## loading code which is first sent to R on remote sessions
|
||||
local({
|
||||
curver <- '%s'
|
||||
## MM: ok for Windows?
|
||||
## VS: Should be fine (who is using win remote anyways?)
|
||||
.c.dir <- '~/.config/ESSR'
|
||||
verfile <- file.path(.c.dir, 'VERSION')
|
||||
envfile <- file.path(.c.dir, 'ESSR.rda')
|
||||
ver <- if(file.exists(verfile)) scan(verfile, what = "string") else "0.0"
|
||||
tryCatch({
|
||||
if(ver < curver) {
|
||||
url <- paste('http://vitalie.spinu.info/ESSR/ESSR_', curver, '.rda', sep = '')
|
||||
if(!file.exists(.c.dir))
|
||||
dir.create(.c.dir, recursive = TRUE)
|
||||
utils::download.file(url, envfile)
|
||||
cat(curver, file = verfile)
|
||||
}
|
||||
load(envfile)
|
||||
attach(ESSR)
|
||||
print(TRUE)
|
||||
} , error = function(e) print(FALSE))
|
||||
})
|
85
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/.basic.R
Normal file
85
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/.basic.R
Normal file
@@ -0,0 +1,85 @@
|
||||
#### Essential functionality needed by ESS
|
||||
|
||||
## Should work on *all* vesions of R.
|
||||
## Do not use _ in names, nor :: , nor 1L etc, as they
|
||||
## cannot be parsed in old R versions
|
||||
|
||||
|
||||
## loading ESSR.rda might fail, so re-assign here:
|
||||
.ess.Rversion <-
|
||||
if( exists("getRversion", mode="function") ){
|
||||
getRversion()
|
||||
} else {
|
||||
paste(R.version$major, R.version$minor, sep=".")
|
||||
}
|
||||
|
||||
.ess.R.has.utils <- (.ess.Rversion >= "1.9.0")
|
||||
.ess.utils.name <- paste("package",
|
||||
if(.ess.Rversion >= "1.9.0") "utils" else "base",
|
||||
sep = ":")
|
||||
|
||||
## Instead of modern utils::help use one that works in R 1.0.0:
|
||||
.ess.findFUN <- get("find", .ess.utils.name)
|
||||
.ess.sourceFUN <- get("source", pos="package:base")
|
||||
.ess.helpFUN <- get("help", envir=.GlobalEnv)# so it also works with d..tools
|
||||
|
||||
### HELP
|
||||
.ess.help <- function(..., help.type = getOption('help_type'))
|
||||
{
|
||||
if (.ess.Rversion > '2.10')# abbreviating 'help_type' on purpose:
|
||||
.ess.helpFUN(..., help = help.type)
|
||||
else # not using identical(), and working also for NULL:
|
||||
.ess.helpFUN(..., htmlhelp = (length(help.type) && help.type=='html'))
|
||||
}
|
||||
|
||||
.ess.getHelpAliases <- function(){
|
||||
readrds <-
|
||||
if(.ess.Rversion >= '2.13.0') readRDS
|
||||
else .readRDS
|
||||
rds.files <- paste(searchpaths(), "/help/aliases.rds", sep = "")
|
||||
unlist(lapply(rds.files,
|
||||
function(f){
|
||||
if( file.exists(f) )
|
||||
try(names(readrds(f)))
|
||||
}),
|
||||
use.names = FALSE)
|
||||
}
|
||||
|
||||
### SOURCING
|
||||
.ess.eval <- function(string, echo = TRUE, print.eval = TRUE,
|
||||
max.deparse.length = 300,
|
||||
file = tempfile("ESS"),
|
||||
local = if (.ess.Rversion > '2.13') parent.frame() else FALSE)
|
||||
{
|
||||
## create FILE, put string into it. Then source.
|
||||
## arguments are like in source and .ess.source
|
||||
cat(string, file = file)
|
||||
on.exit(file.remove(file))
|
||||
.ess.source(file, echo = echo, print.eval = print.eval,
|
||||
max.deparse.length = max.deparse.length, local = local)
|
||||
}
|
||||
|
||||
.ess.source <- function(file, echo = TRUE, print.eval = TRUE,
|
||||
max.deparse.length = 300,
|
||||
local = if (.ess.Rversion > '2.13') parent.frame() else FALSE)
|
||||
{
|
||||
ss <- # drop 'keep.source' for older versions
|
||||
if(.ess.Rversion >= "2.8") .ess.sourceFUN
|
||||
else function(..., keep.source) .ess.sourceFUN(...)
|
||||
invisible(ss(file, echo = echo, local = local, print.eval = print.eval,
|
||||
max.deparse.length = max.deparse.length,
|
||||
keep.source = TRUE)$value) ## return value for org-babel
|
||||
}
|
||||
|
||||
if(.ess.Rversion < "1.8")
|
||||
## (works for "1.7.2"): bquote() was new in 1.8.0
|
||||
bquote <- function(expr, where=parent.frame()){
|
||||
unquote <- function(e)
|
||||
if (is.pairlist(e)) as.pairlist(lapply(e, unquote))
|
||||
else if (length(e) <= 1) e
|
||||
else if (e[[1]] == as.name(".")) eval(e[[2]], where)
|
||||
else as.call(lapply(e, unquote))
|
||||
|
||||
unquote(substitute(expr))
|
||||
}
|
||||
|
53
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/.load.R
Normal file
53
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/.load.R
Normal file
@@ -0,0 +1,53 @@
|
||||
## Do not use _ in names, nor :: as they cannot be parsed in old R versions
|
||||
|
||||
## load .base.R and all other files into ESSR environment; then attach ESSR
|
||||
load.ESSR <- function(dir){
|
||||
.source <-
|
||||
if(any("keep.source" == names(formals(sys.source))))
|
||||
sys.source
|
||||
else
|
||||
function(..., keep.source) sys.source(...)
|
||||
|
||||
Rver <-
|
||||
if(exists("getRversion", mode="function")) getRversion()
|
||||
else paste(R.version$major, R.version$minor, sep=".")
|
||||
|
||||
oldR <- Rver <= "1.3.0"
|
||||
|
||||
ESSR <-
|
||||
if(oldR) ## really old library() revert order a bit
|
||||
attach(NULL, name = "ESSR")
|
||||
else if(length(nn <- names(formals(new.env))) && any(nn == "parent"))
|
||||
new.env(parent =
|
||||
if(Rver >= "1.9.0") getNamespace("utils")
|
||||
else .BaseNamespaceEnv)
|
||||
else
|
||||
new.env()
|
||||
|
||||
assign(".ess.Rversion", Rver, envir = ESSR)
|
||||
|
||||
ESSRver <- scan(paste(dirname(dir), "/VERSION", sep = ""),
|
||||
what = "character", quiet = TRUE)
|
||||
assign(".ess.ESSRversion", ESSRver, envir = ESSR)
|
||||
|
||||
|
||||
## .basic.R:
|
||||
try(.source(paste(dir,'/.basic.R', sep = ""), envir = ESSR, keep.source = FALSE))
|
||||
|
||||
## all others try(*) as it will fail in old R
|
||||
if(!oldR) # no sense if(oldR)
|
||||
for( f in dir(dir, pattern='\\.R$', full.names=TRUE) )
|
||||
try(.source(f, envir = ESSR, keep.source = FALSE))
|
||||
|
||||
if(Rver >= "2.4.0")
|
||||
attach(ESSR)
|
||||
else if(!oldR) { ## borrow from older library()
|
||||
e <- attach(NULL, name = "ESSR")
|
||||
.Internal(lib.fixup(ESSR, e))
|
||||
} else { ## if(oldR), use as in that old library():
|
||||
.Internal(lib.fixup(ESSR, .GlobalEnv))
|
||||
}
|
||||
|
||||
## BUILDESSR needs this:
|
||||
invisible(ESSR)
|
||||
}
|
100
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/completion.R
Normal file
100
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/completion.R
Normal file
@@ -0,0 +1,100 @@
|
||||
## Do *NOT* use 1L -- it gives parse errors in historical versions of R
|
||||
|
||||
.ess_funargs <- function(funname) {
|
||||
if(.ess.Rversion > '2.14.1') {
|
||||
comp <- compiler::enableJIT(0)
|
||||
op <- options(error=NULL)
|
||||
on.exit({ options(op); compiler::enableJIT(comp) })
|
||||
}
|
||||
## don't remove; really need eval(parse( here!!
|
||||
fun <- tryCatch(eval(parse(text=funname)),
|
||||
error=function(e) NULL) ## also works for special objects containing @:$ etc
|
||||
if(is.function(fun)) {
|
||||
special <- grepl('[:$@[]', funname)
|
||||
args <- if(!special){
|
||||
fundef <- paste(funname, '.default',sep='')
|
||||
do.call('argsAnywhere', list(fundef))
|
||||
}
|
||||
|
||||
if(is.null(args))
|
||||
args <- args(fun)
|
||||
if(is.null(args))
|
||||
args <- do.call('argsAnywhere', list(funname))
|
||||
|
||||
fmls <- formals(args)
|
||||
fmls_names <- names(fmls)
|
||||
fmls <- gsub('\"', '\\\"',
|
||||
gsub("\\", "\\\\", as.character(fmls),fixed = TRUE),
|
||||
fixed=TRUE)
|
||||
args_alist <-
|
||||
sprintf("'(%s)",
|
||||
paste("(\"", fmls_names, "\" . \"", fmls, "\")",
|
||||
sep = '', collapse = ' '))
|
||||
allargs <-
|
||||
if(special) fmls_names
|
||||
else tryCatch(gsub('=', '', utils:::functionArgs(funname, ''), fixed = TRUE),
|
||||
error=function(e) NULL)
|
||||
allargs <- sprintf("'(\"%s\")",
|
||||
paste(allargs, collapse = '\" "'))
|
||||
envname <- environmentName(environment(fun))
|
||||
if(envname == "R_GlobalEnv") envname <- ""
|
||||
cat(sprintf('(list \"%s\" %s %s)\n',
|
||||
envname, args_alist, allargs))
|
||||
}
|
||||
}
|
||||
|
||||
.ess_get_completions <- function(string, end){
|
||||
if(.ess.Rversion > '2.14.1'){
|
||||
comp <- compiler::enableJIT(0)
|
||||
op <- options(error=NULL)
|
||||
on.exit({ options(op); compiler::enableJIT(comp) })
|
||||
}
|
||||
utils:::.assignLinebuffer(string)
|
||||
utils:::.assignEnd(end)
|
||||
utils:::.guessTokenFromLine()
|
||||
utils:::.completeToken()
|
||||
c(get('token', envir=utils:::.CompletionEnv),
|
||||
utils:::.retrieveCompletions())
|
||||
}
|
||||
|
||||
.ess_arg_help <- function(arg, func){
|
||||
op <- options(error=NULL)
|
||||
on.exit(options(op))
|
||||
fguess <-
|
||||
if(is.null(func)) get('fguess', envir=utils:::.CompletionEnv)
|
||||
else func
|
||||
findArgHelp <- function(fun, arg){
|
||||
file <- help(fun, try.all.packages=FALSE)[[1]]
|
||||
hlp <- utils:::.getHelpFile(file)
|
||||
id <- grep('arguments', tools:::RdTags(hlp), fixed=TRUE)
|
||||
if(length(id)){
|
||||
arg_section <- hlp[[id[[1]]]]
|
||||
items <- grep('item', tools:::RdTags(arg_section), fixed=TRUE)
|
||||
## cat('items:', items, fill=TRUE)
|
||||
if(length(items)){
|
||||
arg_section <- arg_section[items]
|
||||
args <- unlist(lapply(arg_section,
|
||||
function(el) paste(unlist(el[[1]][[1]], TRUE, FALSE), collapse='')))
|
||||
fits <- grep(arg, args, fixed=TRUE)
|
||||
## cat('args', args, 'fits', fill=TRUE)
|
||||
if(length(fits))
|
||||
paste(unlist(arg_section[[fits[1]]][[2]], TRUE, FALSE), collapse='')
|
||||
}
|
||||
}
|
||||
}
|
||||
funcs <- c(fguess, tryCatch(methods(fguess),
|
||||
warning=function(w) {NULL},
|
||||
error=function(e) {NULL}))
|
||||
if(length(funcs) > 1 && length(pos <- grep('default', funcs))){
|
||||
funcs <- c(funcs[[pos[[1]]]], funcs[-pos[[1]]])
|
||||
}
|
||||
i <- 1; found <- FALSE
|
||||
out <- 'No help found'
|
||||
while(i <= length(funcs) && is.null(out <-
|
||||
tryCatch(findArgHelp(funcs[[i]], arg),
|
||||
warning=function(w) {NULL},
|
||||
error=function(e) {NULL})
|
||||
))
|
||||
i <- i + 1
|
||||
cat('\n\n', as.character(out), '\n')
|
||||
};
|
187
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/debug.R
Normal file
187
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/debug.R
Normal file
@@ -0,0 +1,187 @@
|
||||
|
||||
### BREAKPOINTS
|
||||
.ESSBP. <- new.env()
|
||||
|
||||
### DEBUG/UNDEBUG
|
||||
.ess_find_funcs <- function(env)
|
||||
{
|
||||
objs <- ls(envir = env, all.names = TRUE)
|
||||
objs[sapply(objs, exists, envir = env,
|
||||
mode = 'function', inherits = FALSE)]
|
||||
}
|
||||
|
||||
.ess_all_functions <- function(packages = c(), env = NULL)
|
||||
{
|
||||
if(is.null(env))
|
||||
env <- parent.frame()
|
||||
empty <- emptyenv()
|
||||
coll <- list()
|
||||
for(p in packages){
|
||||
## package might not be attached
|
||||
try({objNS <- .ess_find_funcs(asNamespace(p))
|
||||
objPKG <- .ess_find_funcs(as.environment(paste0('package:', p)))
|
||||
coll[[length(coll) + 1]] <-
|
||||
paste0(p, ':::`', setdiff(objNS, objPKG), '`')
|
||||
}, silent = TRUE)
|
||||
}
|
||||
while(!identical(empty, env)){
|
||||
coll[[length(coll) + 1]] <- .ess_find_funcs(env)
|
||||
env <- parent.env(env)
|
||||
}
|
||||
grep('^\\.ess', unlist(coll, use.names = FALSE),
|
||||
invert = TRUE, value = TRUE)
|
||||
}
|
||||
|
||||
.ess_dbg_getTracedAndDebugged <- function(packages = c())
|
||||
{
|
||||
tr_state <- tracingState(FALSE)
|
||||
on.exit(tracingState(tr_state))
|
||||
generics <- methods::getGenerics()
|
||||
all_traced <- c()
|
||||
for(i in seq_along(generics)){
|
||||
genf <- methods::getGeneric(generics[[i]],
|
||||
package=generics@package[[i]])
|
||||
if(!is.null(genf)){ ## might happen !! v.2.13
|
||||
menv <- methods::getMethodsForDispatch(genf)
|
||||
traced <- unlist(eapply(menv, is, 'traceable', all.names=TRUE))
|
||||
if(length(traced) && any(traced))
|
||||
all_traced <- c(paste(generics[[i]],':',
|
||||
names(traced)[traced],sep=''), all_traced)
|
||||
tfn <- getFunction(generics[[i]], mustFind=FALSE, where = .GlobalEnv)
|
||||
if(!is.null(tfn ) && is(tfn, 'traceable')) # if the default is traced, it does not appear in the menv :()
|
||||
all_traced <- c(generics[[i]], all_traced)
|
||||
}
|
||||
}
|
||||
debugged_pkg <- unlist(lapply(packages, function(pkgname){
|
||||
ns <- asNamespace(pkgname)
|
||||
funcs <- .ess_find_funcs(ns)
|
||||
dbged <- funcs[unlist(lapply(funcs,
|
||||
function(f){
|
||||
isdebugged(get(f, envir = ns, inherits = FALSE))
|
||||
}))]
|
||||
if(length(dbged))
|
||||
paste0(pkgname, ':::`', dbged, '`')
|
||||
}))
|
||||
env <- parent.frame()
|
||||
## traced function don't appear here. Not realy needed and would affect performance.
|
||||
all <- .ess_all_functions(packages = packages, env = env)
|
||||
which_deb <- lapply(all, function(nm){
|
||||
## if isdebugged is called with string it doess find
|
||||
tryCatch(isdebugged(get(nm, envir = env)),
|
||||
error = function(e) FALSE)
|
||||
## try(eval(substitute(isdebugged(nm), list(nm = as.name(nm)))), silent = T)
|
||||
})
|
||||
debugged <- all[which(unlist(which_deb, recursive=FALSE, use.names=FALSE))]
|
||||
unique(c(debugged_pkg, debugged, all_traced))
|
||||
}
|
||||
|
||||
.ess_dbg_UntraceOrUndebug <- function(name, env = parent.frame())
|
||||
{
|
||||
tr_state <- tracingState(FALSE)
|
||||
on.exit(tracingState(tr_state))
|
||||
if( grepl('::', name) ){
|
||||
## foo:::bar name
|
||||
eval(parse(text = sprintf('undebug(%s)', name)))
|
||||
}else{
|
||||
## name is a name of a function to be undebugged or has a form
|
||||
## name:Class1#Class2#Class3 for traced methods
|
||||
name <- strsplit(name, ':', fixed = TRUE)[[1]]
|
||||
if( length(name)>1 ){
|
||||
## a method
|
||||
fun <- name[[1]]
|
||||
sig <- strsplit(paste(name[-1], collapse=''), '#', fixed=TRUE)[[1]]
|
||||
untrace(fun, signature = sig)
|
||||
}else{
|
||||
## function
|
||||
if( is(getFunction(name, where = parent.frame()), 'traceable') )
|
||||
untrace(name)
|
||||
else if(grepl(":", name))
|
||||
undebug(name)
|
||||
else
|
||||
undebug(get(name, envir = env))
|
||||
}}
|
||||
}
|
||||
|
||||
.ess_dbg_UndebugALL <- function(funcs)
|
||||
{
|
||||
tr_state <- tracingState(FALSE)
|
||||
on.exit(tracingState(tr_state))
|
||||
env <- parent.frame()
|
||||
invisible(lapply(funcs, function( nm ) {
|
||||
## ugly tryCatch, but there might be several names pointing to the
|
||||
## same function, like foo:::bar and bar. An alternative would be
|
||||
## to call .ess_dbg_getTracedAndDebugged each time but that might
|
||||
## be ery slow
|
||||
try(.ess_dbg_UntraceOrUndebug(nm, env = env), TRUE)
|
||||
}))
|
||||
}
|
||||
|
||||
### WATCH
|
||||
.ess_watch_expressions <- list()
|
||||
|
||||
.ess_watch_eval <- function()
|
||||
{
|
||||
env <- as.environment("ESSR")
|
||||
exps <- get('.ess_watch_expressions', envir = env)
|
||||
if(length(exps) == 0) {
|
||||
## using old style so this can be parsed by R 1.9.1 (e.g):
|
||||
cat('\n# Watch list is empty!\n',
|
||||
'# a append new expression',
|
||||
'# i insert new expression',
|
||||
'# k kill',
|
||||
'# e edit the expression',
|
||||
'# r rename',
|
||||
'# n/p navigate',
|
||||
'# u/d,U move the expression up/down',
|
||||
'# q kill the buffer',
|
||||
sep="\n")
|
||||
} else {
|
||||
.parent_frame <- parent.frame()
|
||||
.essWEnames <- allNames(exps)
|
||||
len0p <- !nzchar(.essWEnames)
|
||||
.essWEnames[len0p] <- seq_along(len0p)[len0p]
|
||||
for(i in seq_along(exps)) {
|
||||
cat('\n@---- ', .essWEnames[[i]], ' ',
|
||||
rep.int('-', max(0, 35 - nchar(.essWEnames[[i]]))), '-@\n', sep = '')
|
||||
cat(paste('@---:', deparse(exps[[i]][[1]])), ' \n', sep = '')
|
||||
tryCatch(print(eval(exps[[i]],
|
||||
envir = .parent_frame)),
|
||||
error = function(e) cat('Error:', e$message, '\n' ),
|
||||
warning = function(w) cat('warning: ', w$message, '\n' ))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ess_watch_assign_expressions <- function(elist){
|
||||
assign(".ess_watch_expressions", elist, envir = as.environment("ESSR"))
|
||||
}
|
||||
|
||||
.ess_log_eval <- function(log_name)
|
||||
{
|
||||
env <- as.environment("ESSR")
|
||||
if(!exists(log_name, envir = env, inherits = FALSE))
|
||||
assign(log_name, list(), envir = env)
|
||||
log <- get(log_name, envir = env, inherits = FALSE)
|
||||
.essWEnames <- allNames(.ess_watch_expressions)
|
||||
cur_log <- list()
|
||||
.parent_frame <- parent.frame()
|
||||
for(i in seq_along(.ess_watch_expressions)) {
|
||||
capture.output( {
|
||||
cur_log[[i]] <-
|
||||
tryCatch(eval(.ess_watch_expressions[[i]]),
|
||||
envir = .parent_frame,
|
||||
error = function(e) paste('Error:', e$message, '\n'),
|
||||
warning = function(w) paste('warning: ', w$message, '\n'))
|
||||
if(is.null(cur_log[i][[1]]))
|
||||
cur_log[i] <- list(NULL)
|
||||
})
|
||||
}
|
||||
names(cur_log) <- .essWEnames
|
||||
assign(log_name, c(log, list(cur_log)), envir = env)
|
||||
invisible(NULL)
|
||||
}
|
||||
|
||||
.ess_package_attached <- function(pack_name){
|
||||
as.logical(match(paste0("package:", pack_name), search()))
|
||||
}
|
||||
|
295
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/developer.R
Normal file
295
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/developer.R
Normal file
@@ -0,0 +1,295 @@
|
||||
## COMMENT ON S3 METHODS: New S3 methods are not automatically registered. You can
|
||||
## register them manually after you have inserted method_name.my_class into your
|
||||
## package environment using ess-developer, like follows:
|
||||
##
|
||||
## registerS3method("method_name", "my_class", my_package:::method_name.my_class)
|
||||
##
|
||||
## If an S3 methods already exists in a package, ESS-developer will do the right
|
||||
## thing.
|
||||
|
||||
## evaluate the STRING by saving into a file and calling .essDev_source
|
||||
.essDev.eval <- function(string, package, file = tempfile("ESSDev")){
|
||||
cat(string, file = file)
|
||||
on.exit(file.remove(file))
|
||||
.essDev_source(file,, package = package)
|
||||
}
|
||||
|
||||
## sourcing SOURCE file into an environment. After having a look at each new
|
||||
## object in the environment, decide what to do with it. Handles plain objects,
|
||||
## functions, existing S3 methods, S4 classes and methods. .
|
||||
.essDev_source <- function(source, expr, package = "")
|
||||
{
|
||||
## require('methods')
|
||||
oldopts <- options(warn = 1)
|
||||
on.exit(options(oldopts))
|
||||
MPattern <- methods:::.TableMetaPattern()
|
||||
CPattern <- methods:::.ClassMetaPattern()
|
||||
allPlainObjects <- function() allObjects[!(grepl(MPattern, allObjects) |
|
||||
grepl(CPattern, allObjects))]
|
||||
allMethodTables <- function() allObjects[grepl(MPattern, allObjects)]
|
||||
allClassDefs <- function() allObjects[grepl(CPattern, allObjects)]
|
||||
pname <- paste("package:", package, sep = "")
|
||||
envpkg <- tryCatch(as.environment(pname), error = function(cond) NULL)
|
||||
if(is.null(envpkg)){
|
||||
library(package, character.only = TRUE)
|
||||
envpkg <- tryCatch(as.environment(pname), error = function(cond) NULL)
|
||||
}
|
||||
if (is.null(envpkg))
|
||||
stop(gettextf("Can't find an environment corresponding to package name '%s'",
|
||||
package), domain = NA)
|
||||
envns <- tryCatch(asNamespace(package), error = function(cond) NULL)
|
||||
if (is.null(envns))
|
||||
stop(gettextf("Can't find a namespace environment corresponding to package name '%s\"",
|
||||
package), domain = NA)
|
||||
|
||||
## evaluate the SOURCE into new ENV
|
||||
env <- .essDev_evalSource(source, substitute(expr), package)
|
||||
envPackage <- getPackageName(env, FALSE)
|
||||
if (nzchar(envPackage) && envPackage != package)
|
||||
warning(gettextf("Supplied package, %s, differs from package inferred from source, %s",
|
||||
sQuote(package), sQuote(envPackage)), domain = NA)
|
||||
|
||||
allObjects <- objects(envir = env, all.names = TRUE)
|
||||
allObjects <- allObjects[!(allObjects %in% c(".cacheOnAssign", ".packageName"))]
|
||||
|
||||
## PLAIN OBJECTS and FUNCTIONS:
|
||||
funcNs <- funcPkg <- newFunc <- newNs <- newObjects <- newPkg <- objectsNs <- objectsPkg <- character()
|
||||
|
||||
for (this in allPlainObjects()) {
|
||||
thisEnv <- get(this, envir = env)
|
||||
thisNs <- NULL
|
||||
|
||||
## NS
|
||||
if (exists(this, envir = envns, inherits = FALSE)){
|
||||
thisNs <- get(this, envir = envns)
|
||||
if(is.function(thisNs) || is.function(thisEnv)){
|
||||
if(is.function(thisNs) && is.function(thisEnv)){
|
||||
if(.essDev_differs(thisEnv, thisNs)){
|
||||
environment(thisEnv) <- environment(thisNs)
|
||||
.essDev_assign(this, thisEnv, envns)
|
||||
funcNs <- c(funcNs, this)
|
||||
if(exists(".__S3MethodsTable__.", envir = envns, inherits = FALSE)){
|
||||
S3_table <- get(".__S3MethodsTable__.", envir = envns)
|
||||
if(exists(this, envir = S3_table, inherits = FALSE))
|
||||
.essDev_assign(this, thisEnv, S3_table)
|
||||
}
|
||||
}
|
||||
}else{
|
||||
newNs <- c(newNs, this)
|
||||
}
|
||||
}else{
|
||||
if(!identical(thisEnv, thisNs)){
|
||||
.essDev_assign(this, thisEnv, envns)
|
||||
objectsNs <- c(objectsNs, this)}
|
||||
}
|
||||
}else{
|
||||
newNs <- c(newNs, this)
|
||||
}
|
||||
|
||||
## PKG
|
||||
if (exists(this, envir = envpkg, inherits = FALSE)){
|
||||
thisPkg <- get(this, envir = envpkg)
|
||||
if(is.function(thisPkg) || is.function(thisEnv)){
|
||||
if(is.function(thisPkg) && is.function(thisEnv)){
|
||||
if(.essDev_differs(thisPkg, thisEnv)){
|
||||
environment(thisEnv) <- environment(thisPkg)
|
||||
.essDev_assign(this, thisEnv, envpkg)
|
||||
funcPkg <- c(funcPkg, this)}
|
||||
}else{
|
||||
newPkg <- c(newPkg, this)}
|
||||
}else{
|
||||
if(!identical(thisPkg, thisEnv)){
|
||||
.essDev_assign(this, thisEnv, envpkg)
|
||||
objectsPkg <- c(objectsPkg, this)}}
|
||||
}else{
|
||||
newPkg <- c(newPkg, this)}
|
||||
}
|
||||
|
||||
## deal with new plain objects and functions
|
||||
for(this in intersect(newPkg, newNs)){
|
||||
thisEnv <- get(this, envir = env, inherits = FALSE)
|
||||
if(exists(this, envir = .GlobalEnv, inherits = FALSE)){
|
||||
thisGl <- get(this, envir = .GlobalEnv)
|
||||
if(.essDev_differs(thisEnv, thisGl)){
|
||||
if(is.function(thisEnv)){
|
||||
environment(thisEnv) <- envns
|
||||
newFunc <- c(newFunc, this)
|
||||
}else{
|
||||
newObjects <- c(newObjects, this)
|
||||
}
|
||||
.essDev_assign(this, thisEnv, .GlobalEnv)
|
||||
}
|
||||
}else{
|
||||
if(is.function(thisEnv)){
|
||||
environment(thisEnv) <- envns
|
||||
newFunc <- c(newFunc, this)
|
||||
}else{
|
||||
newObjects <- c(newObjects, this)
|
||||
}
|
||||
.essDev_assign(this, thisEnv, .GlobalEnv)
|
||||
}
|
||||
}
|
||||
if(length(funcNs))
|
||||
objectsNs <- c(objectsNs, sprintf("FUN[%s]", paste(funcNs, collapse = ", ")))
|
||||
if(length(funcPkg))
|
||||
objectsPkg <- c(objectsPkg, sprintf("FUN[%s]", paste(funcPkg, collapse = ", ")))
|
||||
if(length(newFunc))
|
||||
newObjects <- c(newObjects, sprintf("FUN[%s]", paste(newFunc, collapse = ", ")))
|
||||
|
||||
## CLASSES
|
||||
classesPkg <- classesNs <- newClasses <- character()
|
||||
for(this in allClassDefs()){
|
||||
newPkg <- newNs <- FALSE
|
||||
thisEnv <- get(this, envir = env)
|
||||
if(exists(this, envir = envpkg, inherits = FALSE)){
|
||||
if(!.essDev_identicalClass(thisEnv, get(this, envir = envpkg))){
|
||||
.essDev_assign(this, thisEnv, envir = envpkg)
|
||||
classesPkg <- c(classesPkg, this)
|
||||
}
|
||||
}else{
|
||||
newPkg <- TRUE
|
||||
}
|
||||
if(exists(this, envir = envns, inherits = FALSE)){
|
||||
if(!.essDev_identicalClass(thisEnv, get(this, envir = envns))){
|
||||
.essDev_assign(this, thisEnv, envir = envns)
|
||||
classesNs <- c(classesNs, this)
|
||||
}
|
||||
}else{
|
||||
newNs <- TRUE
|
||||
}
|
||||
if(newNs && newPkg){
|
||||
if(exists(this, envir = .GlobalEnv, inherits = FALSE)){
|
||||
if(!.essDev_identicalClass(thisEnv, get(this, envir = .GlobalEnv))){
|
||||
.essDev_assign(this, thisEnv, envir = .GlobalEnv)
|
||||
newClasses <- c(newClasses, this)
|
||||
}
|
||||
}else{
|
||||
.essDev_assign(this, thisEnv, envir = .GlobalEnv)
|
||||
newClasses <- c(newClasses, this)
|
||||
}
|
||||
}
|
||||
}
|
||||
if(length(classesPkg))
|
||||
objectsPkg <- gettextf("CLS[%s]", sub(methods:::.ClassMetaPattern(), "", paste(classesPkg, collapse = ", ")))
|
||||
if(length(classesNs))
|
||||
objectsNs <- gettextf("CLS[%s]", sub(methods:::.ClassMetaPattern(), "", paste(classesNs, collapse = ", ")))
|
||||
if(length(newClasses))
|
||||
newObjects <- gettextf("CLS[%s]", sub(methods:::.ClassMetaPattern(), "", paste(newClasses, collapse = ", ")))
|
||||
|
||||
## METHODS:
|
||||
## Method internals: For efficiency reasons setMethod() caches
|
||||
## method definition into a global table which you can get with
|
||||
## 'getMethodsForDispatch' function, and when a method is dispatched that
|
||||
## table is used. When ess-developer is used to source method definitions the
|
||||
## two copies of the functions are identical up to the environment. The
|
||||
## environment of the cached object has namespace:foo as it's parent but the
|
||||
## environment of the object in local table is precisely namspace:foo. This
|
||||
## does not cause any difference in evaluation.
|
||||
methodNames <- allMethodTables()
|
||||
methods <- sub(methods:::.TableMetaPrefix(), "", methodNames)
|
||||
methods <- sub(":.*", "", methods)
|
||||
methodsNs <- newMethods <- character()
|
||||
for (i in seq_along(methods)){
|
||||
table <- methodNames[[i]]
|
||||
tableEnv <- get(table, envir = env)
|
||||
if(exists(table, envir = envns, inherits = FALSE)){
|
||||
inserted <- .essDev_insertMethods(tableEnv, get(table, envir = envns), envns)
|
||||
if(length(inserted))
|
||||
methodsNs <- c(methodsNs, gettextf("%s{%s}", methods[[i]], paste(inserted, collapse = ", ")))
|
||||
}else if(exists(table, envir = .GlobalEnv, inherits = FALSE)){
|
||||
inserted <- .essDev_insertMethods(tableEnv, get(table, envir = .GlobalEnv), envns)
|
||||
if(length(inserted))
|
||||
newMethods <- c(newMethods, gettextf("%s{%s}", methods[[i]], paste(inserted, collapse = ", ")))
|
||||
}else{
|
||||
.essDev_assign(table, tableEnv, envir = .GlobalEnv)
|
||||
newMethods <- c(newMethods, gettextf("%s{%s}", methods[[i]], paste(objects(envir = tableEnv, all.names = T), collapse = ", ")))
|
||||
}
|
||||
}
|
||||
if(length(methodsNs))
|
||||
objectsNs <- c(objectsNs, gettextf("METH[%s]", paste(methodsNs, collapse = ", ")))
|
||||
if(length(newMethods))
|
||||
newObjects <- c(newObjects, gettextf("METH[%s]", paste(newMethods, collapse = ", ")))
|
||||
|
||||
if(length(objectsPkg))
|
||||
cat(sprintf("%s PKG: %s ", package, paste(objectsPkg, collapse = ", ")))
|
||||
if(length(objectsNs))
|
||||
cat(sprintf("NS: %s ", paste(objectsNs, collapse = ", ")))
|
||||
if(length(newObjects))
|
||||
cat(sprintf("GlobalEnv: %s\n", paste(newObjects, collapse = ", ")))
|
||||
if(length(c(objectsNs, objectsPkg, newObjects)) == 0)
|
||||
cat(sprintf("*** Nothing explicitly assigned ***\n"))
|
||||
invisible(env)
|
||||
}
|
||||
|
||||
.essDev_insertMethods <- function(tableEnv, tablePkg, envns)
|
||||
{
|
||||
inserted <- character()
|
||||
for(m in ls(envir = tableEnv, all.names = T)){
|
||||
if(exists(m, envir = tablePkg, inherits = FALSE)){
|
||||
thisEnv <- get(m, envir = tableEnv)
|
||||
thisPkg <- get(m, envir = tablePkg)
|
||||
if(is(thisEnv, "MethodDefinition") && is(thisPkg, "MethodDefinition") &&
|
||||
.essDev_differs(thisEnv@.Data, thisPkg@.Data)){
|
||||
environment(thisEnv@.Data) <- envns
|
||||
## environment of cached method in getMethodsForDispatch table is still env
|
||||
## not a problem as such, but might confuse users
|
||||
.essDev_assign(m, thisEnv, tablePkg)
|
||||
inserted <- c(inserted, m)
|
||||
}}}
|
||||
inserted
|
||||
}
|
||||
|
||||
|
||||
.essDev_evalSource <- function (source, expr, package = "")
|
||||
{
|
||||
envns <- tryCatch(asNamespace(package), error = function(cond) NULL)
|
||||
if(is.null(envns))
|
||||
stop(gettextf("Package \"%s\" is not attached and no namespace found for it",
|
||||
package), domain = NA)
|
||||
env <- new.env(parent = envns)
|
||||
env[[".packageName"]] <- package
|
||||
methods:::setCacheOnAssign(env, TRUE)
|
||||
if (missing(source))
|
||||
eval(expr, envir = env)
|
||||
else if (is(source, "character"))
|
||||
for (text in source) sys.source(text, envir = env, keep.source = TRUE)
|
||||
else stop(gettextf("Invalid source argument: got an object of class \"%s\"",
|
||||
class(source)[[1]]), domain = NA)
|
||||
env
|
||||
}
|
||||
|
||||
|
||||
.essDev_assign <- function (x, value, envir)
|
||||
{
|
||||
if (exists(x, envir = envir, inherits = FALSE) && bindingIsLocked(x, envir)) {
|
||||
unlockBinding(x, envir)
|
||||
assign(x, value, envir = envir, inherits = FALSE)
|
||||
op <- options(warn = -1)
|
||||
on.exit(options(op))
|
||||
lockBinding(x, envir)
|
||||
} else {
|
||||
assign(x, value, envir = envir, inherits = FALSE)
|
||||
}
|
||||
invisible(NULL)
|
||||
}
|
||||
|
||||
.essDev_identicalClass <- function(cls1, cls2, printInfo = FALSE){
|
||||
slots1 <- slotNames(class(cls1))
|
||||
slots2 <- slotNames(class(cls2))
|
||||
if(identical(slots1, slots2)){
|
||||
vK <- grep("versionKey", slots1)
|
||||
if(length(vK))
|
||||
slots1 <- slots2 <- slots1[-vK]
|
||||
out <- sapply(slots1, function(nm) identical(slot(cls1, nm), slot(cls2, nm)))
|
||||
if(printInfo) print(out)
|
||||
all(out)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.essDev_differs <- function(f1, f2) {
|
||||
if (is.function(f1) && is.function(f2)){
|
||||
!(identical(body(f1), body(f2)) && identical(args(f1), args(f2)))
|
||||
}else
|
||||
!identical(f1, f2)
|
||||
}
|
116
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/misc.R
Normal file
116
.emacs.d/elpa/ess-20160208.453/etc/ESSR/R/misc.R
Normal file
@@ -0,0 +1,116 @@
|
||||
.ess_weave <- function(command, file, encoding = NULL){
|
||||
cmd_symb <- substitute(command)
|
||||
if(grepl('knit|purl', deparse(cmd_symb))) require(knitr)
|
||||
od <- getwd()
|
||||
on.exit(setwd(od))
|
||||
setwd(dirname(file))
|
||||
frame <- parent.frame()
|
||||
if(is.null(encoding))
|
||||
eval(bquote(.(cmd_symb)(.(file))), envir = frame)
|
||||
else
|
||||
eval(bquote(.(cmd_symb)(.(file), encoding = .(encoding))), envir = frame)
|
||||
}
|
||||
|
||||
.ess_knit <- function(file, output = NULL){
|
||||
library(knitr)
|
||||
frame <- parent.frame()
|
||||
od <- getwd()
|
||||
on.exit(setwd(od))
|
||||
setwd(dirname(file))
|
||||
## this bquote is really needed for data.table := operator to work correctly
|
||||
eval(bquote(knit(.(file), output = .(output))), envir = frame)
|
||||
}
|
||||
|
||||
.ess_sweave <- function(file, output = NULL){
|
||||
od <- getwd()
|
||||
frame <- parent.frame()
|
||||
on.exit(setwd(od))
|
||||
setwd(dirname(file))
|
||||
eval(bquote(Sweave(.(file), output = .(output))), envir = frame)
|
||||
}
|
||||
|
||||
## Users might find it useful. So don't prefix with .ess.
|
||||
htsummary <- function (x, hlength = 4, tlength = 4, digits = 3)
|
||||
{
|
||||
## fixme: simplify and generalize
|
||||
snames <- c("mean", "sd", "min", "max", "nlev", "NAs")
|
||||
d <- " "
|
||||
num_sumr <- function(x){
|
||||
c(f(mean(x, na.rm = TRUE)),
|
||||
f(sd(x, na.rm = TRUE)),
|
||||
f(min(x, na.rm = TRUE)),
|
||||
f(max(x, na.rm = TRUE)),
|
||||
d,
|
||||
f(sum(is.na(x), na.rm = TRUE)))
|
||||
}
|
||||
f <- function(x) format(x, digits = digits)
|
||||
|
||||
if (is.data.frame(x) | is.matrix(x)) {
|
||||
if (nrow(x) <= tlength + hlength){
|
||||
print(x)
|
||||
} else {
|
||||
if (is.matrix(x))
|
||||
x <- data.frame(unclass(x))
|
||||
## conversion needed, to avoid problems with derived classes suchs as data.table
|
||||
h <- as.data.frame(head(x, hlength))
|
||||
t <- as.data.frame(tail(x, tlength))
|
||||
for (i in 1:ncol(x)) {
|
||||
h[[i]] <- f(h[[i]])
|
||||
t[[i]] <- f(t[[i]])
|
||||
}
|
||||
## summaries
|
||||
sumr <- sapply(x, function(c){
|
||||
if(is.logical(c))
|
||||
## treat logical as numeric; it's harmless
|
||||
c <- as.integer(c)
|
||||
if(is.numeric(c))
|
||||
num_sumr(c)
|
||||
else if(is.factor(c)) c(d, d, d, d, nlevels(c), sum(is.na(c)))
|
||||
else rep.int(d, length(snames))
|
||||
})
|
||||
sumr <- as.data.frame(sumr)
|
||||
row.names(sumr) <- snames
|
||||
dots <- rep("...", ncol(x))
|
||||
empty <- rep.int(" ", ncol(x))
|
||||
lines <- rep.int(" ", ncol(x))
|
||||
df <- rbind(h, ...= dots, t, `_____` = lines, sumr, ` ` = empty)
|
||||
print(df)
|
||||
}
|
||||
} else {
|
||||
cat("head(", hlength, "):\n", sep = "")
|
||||
print(head(x, hlength))
|
||||
if(length(x) > tlength + hlength){
|
||||
cat("\ntail(", tlength, "):\n", sep = "")
|
||||
print(tail(x, tlength))
|
||||
}
|
||||
cat("_____\n")
|
||||
if(is.numeric(x) || is.logical(x))
|
||||
print(structure(num_sumr(x), names = snames), quote = FALSE)
|
||||
else if(is.factor(x)){
|
||||
cat("NAs: ", sum(is.na(x), na.rm = TRUE), "\n")
|
||||
cat("levels: \n")
|
||||
print(levels(x))
|
||||
}
|
||||
}
|
||||
invisible(NULL)
|
||||
}
|
||||
|
||||
.ess_vignettes <- function(){
|
||||
vs <- unclass(browseVignettes())
|
||||
vs <- vs[sapply(vs, length) > 0]
|
||||
|
||||
mat2elist <- function(mat){
|
||||
if(!is.null(dim(mat))){
|
||||
apply(mat, 1, function(r)
|
||||
sprintf("(list \"%s\")",
|
||||
paste0(gsub("\"","\\\\\"",
|
||||
as.vector(r[c("Title", "Dir", "PDF", "File", "R")])),
|
||||
collapse = "\" \"")))
|
||||
}
|
||||
}
|
||||
cat("(list \n",
|
||||
paste0(mapply(function(el, name) sprintf("(list \"%s\" %s)",
|
||||
name,
|
||||
paste0(mat2elist(el), collapse = "\n")),
|
||||
vs, names(vs)), collapse = "\n"), ")\n")
|
||||
}
|
1
.emacs.d/elpa/ess-20160208.453/etc/ESSR/VERSION
Normal file
1
.emacs.d/elpa/ess-20160208.453/etc/ESSR/VERSION
Normal file
@@ -0,0 +1 @@
|
||||
1.1.8
|
56
.emacs.d/elpa/ess-20160208.453/etc/Extract.factor.Rd
Normal file
56
.emacs.d/elpa/ess-20160208.453/etc/Extract.factor.Rd
Normal file
@@ -0,0 +1,56 @@
|
||||
%% ESS BUG: Indentation ([Tab]) does not work if point is after \arguments{..}
|
||||
%% ------- almost surely because of the (non-escaped) "[".
|
||||
%% and this, all below is original from the R sources (R-devel, 2014-03-05)
|
||||
|
||||
% File src/library/base/man/Extract.factor.Rd
|
||||
% Part of the R package, http://www.R-project.org
|
||||
% Copyright 1995-2010 R Core Team
|
||||
% Distributed under GPL 2 or later
|
||||
|
||||
\name{Extract.factor}
|
||||
\title{Extract or Replace Parts of a Factor}
|
||||
\alias{[.factor}
|
||||
\alias{[<-.factor}
|
||||
\alias{[[.factor}
|
||||
\alias{[[<-.factor}
|
||||
\description{
|
||||
Extract or replace subsets of factors.
|
||||
}
|
||||
\usage{
|
||||
\method{[}{factor}(x, \dots, drop = FALSE)
|
||||
\method{[[}{factor}(x, \dots)
|
||||
\method{[}{factor}(x, \dots) <- value
|
||||
\method{[[}{factor}(x, \dots) <- value
|
||||
}
|
||||
\arguments{
|
||||
\item{x}{a factor}
|
||||
\item{\dots}{a specification of indices -- see \code{\link{Extract}}.}
|
||||
\item{drop}{logical. If true, unused levels are dropped.}
|
||||
\item{value}{character: a set of levels. Factor values are coerced to
|
||||
character.}
|
||||
}
|
||||
\value{
|
||||
A factor with the same set of levels as \code{x} unless \code{drop = TRUE}.
|
||||
}
|
||||
\details{
|
||||
When unused levels are dropped the ordering of the remaining levels is
|
||||
preserved.
|
||||
|
||||
If \code{value} is not in \code{levels(x)}, a missing value is
|
||||
assigned with a warning.
|
||||
|
||||
Any \code{\link{contrasts}} assigned to the factor are preserved
|
||||
unless \code{drop = TRUE}.
|
||||
|
||||
The \code{[[} method supports argument \code{exact}.
|
||||
}
|
||||
\seealso{
|
||||
\code{\link{factor}}, \code{\link{Extract}}.
|
||||
}
|
||||
\examples{
|
||||
## following example(factor)
|
||||
(ff <- factor(substring("statistics", 1:10, 1:10), levels = letters))
|
||||
ff[, drop = TRUE]
|
||||
factor(letters[7:10])[2:3, drop = TRUE]
|
||||
}
|
||||
\keyword{category}
|
69
.emacs.d/elpa/ess-20160208.453/etc/Makefile
Normal file
69
.emacs.d/elpa/ess-20160208.453/etc/Makefile
Normal file
@@ -0,0 +1,69 @@
|
||||
### Makefile - for scripts and icons (./etc) of ESS distribution.
|
||||
###
|
||||
|
||||
## Before making changes here, please take a look at Makeconf
|
||||
include ../Makeconf
|
||||
|
||||
# In ../Makefile we already construct the ESSR-VERSION file :
|
||||
# ESSR_VERSION = $(shell cat ESSR-VERSION)
|
||||
|
||||
#ETCFILES = $(wildcard BACKBUG[S5].BAT backbug[s5] *.S sas-keys.*)
|
||||
#ETCFILES = ESSR.R ess-developer.R SVN-REVISION *.S sas-keys.* ess-sas-sh-command
|
||||
ETCFILES_1 = *.S sas-keys.* ess-sas-sh-command *.jl
|
||||
isRELEASE=$(shell test -f .IS.RELEASE && echo 'yes')
|
||||
ifeq ($(isRELEASE),yes)
|
||||
ETCFILES = .IS.RELEASE git-ref $(ETCFILES_1)
|
||||
else
|
||||
ETCFILES = $(ETCFILES_1)
|
||||
endif
|
||||
|
||||
#ICONS = $(wildcard icons/*.xpm)
|
||||
ICONS = icons/*.xpm
|
||||
|
||||
ESSR_UTIL_FILES = ESSR/LOADREMOTE ESSR/VERSION
|
||||
ESSR_CODE_FILES = ESSR/R/*.R ESSR/R/.*.R
|
||||
# ESSR_tarball = ESSR_$(ESSR_VERSION).tar.gz
|
||||
|
||||
all: #ESSR-VERSION $(ESSR_tarball) library/ESSR
|
||||
|
||||
show-etc:
|
||||
@echo $(ETCFILES)
|
||||
ls -l $(ETCFILES)
|
||||
|
||||
|
||||
## happens "above" as it is need also in ../lisp/ :
|
||||
# ESSR-VERSION: $(ESSR_FILES)
|
||||
# (cd .. ; make etc/ESSR-VERSION)
|
||||
|
||||
# $(ESSR_tarball): $(ESSR_FILES)
|
||||
# R CMD build ESSR
|
||||
# library/ESSR: $(ESSR_tarball)
|
||||
# R CMD INSTALL -l library ESSR
|
||||
|
||||
# rel: $(ESSR_tarball)
|
||||
# [ x$$USER = xmaechler ] || (echo 'must be maechler'; exit 1 )
|
||||
# $(INSTALL) $(ESSR_tarball) $(UPLOAD_DIR)/pkgs/src/contrib
|
||||
|
||||
install :
|
||||
$(INSTALLDIR) $(ETCDIR)/icons
|
||||
$(INSTALLDIR) $(ETCDIR)/ESSR/R
|
||||
$(INSTALL) $(ETCFILES) $(ETCDIR)
|
||||
$(INSTALL) $(ICONS) $(ETCDIR)/icons
|
||||
$(INSTALL) $(ESSR_UTIL_FILES) $(ETCDIR)/ESSR
|
||||
$(INSTALL) $(ESSR_CODE_FILES) $(ETCDIR)/ESSR/R
|
||||
chmod +x $(ETCDIR)/ess-sas-sh-command
|
||||
|
||||
uninstall :
|
||||
-cd $(ETCDIR) && $(UNINSTALL) $(ETCFILES)
|
||||
-cd $(ETCDIR) && $(UNINSTALL) $(ICONS)
|
||||
-cd $(ETCDIR) && $(UNINSTALL) $(ESSR_UTIL_FILES)
|
||||
-cd $(ETCDIR) && $(UNINSTALL) $(ESSR_CODE_FILES)
|
||||
|
||||
|
||||
|
||||
## 'clean' shall remove *exactly* those things that are *not* in version control
|
||||
clean:
|
||||
rm -rf SVN-REVISION
|
||||
## 'distclean' removes also things in VC (svn, when they are remade by "make"):
|
||||
# distclean: clean
|
||||
# rm -rf ESSR_*.tar.gz
|
868
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.R
Normal file
868
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.R
Normal file
@@ -0,0 +1,868 @@
|
||||
#### File showing off things that go wrong or *went* wrong in the past #### -- with R-mode (mostly coded in ../lisp/ess-mode.el )
|
||||
|
||||
### NOTE: this file is indented with RRR style !!!!!
|
||||
### but do not change indentations anymore of anything in here:
|
||||
### expressions are written as we *want* them, not as ESS currently puts them
|
||||
|
||||
options(keep.source = FALSE) # so we see R's deparse() + print() indentation
|
||||
|
||||
|
||||
### --- 1 --------- extraneous comment chars : This seems fixed
|
||||
|
||||
## From: Robert Gentleman <rgentlem@fhcrc.org>
|
||||
## To: Martin Maechler <maechler@stat.math.ethz.ch>
|
||||
## Subject: ESS buglet
|
||||
## Date: Sun, 01 Jul 2007 21:41:24 -0700
|
||||
|
||||
## Hi Martin,
|
||||
## It seems that the following buglet exists (at least in what ever
|
||||
## version I am using)
|
||||
|
||||
##a silly comment
|
||||
##and a second one
|
||||
foo <- function(x=a, abc = list("def", a=1,3,3), more.args, and, bla,
|
||||
blu, bl,
|
||||
another, plus, yet.another, and_mbasd,
|
||||
lots = NULL,
|
||||
more = NULL,
|
||||
args = NULL) {
|
||||
x
|
||||
}
|
||||
|
||||
##- when the line before a function def is a comment, and adding args,
|
||||
##- then new lines, when generated have a comment char at the beginning of
|
||||
##- the line. It is slightly annoying as I have to remove the comment char.
|
||||
##-
|
||||
##- If I add a blank line after the comment line, then the problem does not
|
||||
##- occur.
|
||||
## and another ''anonymous'' function:
|
||||
function(x=a, abc = list("def", a=c(1,3,3)), more.args, and, bla, blu,
|
||||
blo, Abc,
|
||||
def,
|
||||
another, and_another, and_this) {
|
||||
...; ...
|
||||
}
|
||||
|
||||
## This is a "TRUE" example (from Matrix/tests/ ):
|
||||
NA.or.True <- function(x) is.na(x) | x
|
||||
|
||||
abc <- function(x, y, ...) this.is.just.a.one.liner(x,y, z=TRUE, ...)
|
||||
|
||||
## A more-liner function with no "{...}" -- this one even works (but not all!)
|
||||
mindiff <- function(df) df[which.min(df$diff),
|
||||
which.max(df$daff)]
|
||||
|
||||
## Two functions in one line - can I "send" just one of them? {no, not "simply"}
|
||||
f1 <- function(x) be.friendly(x, force=TRUE); f2 <- function(x,y) x*sin(pi*x)
|
||||
|
||||
### --- 2 ----------------------------------------------------------------
|
||||
### --- Suggestion (Jenny Brian): --> Create a (defun ess-eval-multiline .)
|
||||
## Here is useful valid R "test code":
|
||||
|
||||
## From 'example(plot.default)' :
|
||||
|
||||
Speed <- cars$speed
|
||||
Distance <- cars$dist
|
||||
plot(Speed, Distance, panel.first = grid(8,8),
|
||||
pch = 0, cex = 1.2, col = "blue")
|
||||
pp <- plot(Speed, Distance, panel.first = grid(8,8),
|
||||
pch = 0, cex = 1.2, col = "blue")
|
||||
plot(Speed, Distance,
|
||||
panel.first = lines(lowess(Speed, Distance), lty = "dashed"),
|
||||
pch = 0, cex = 1.2, col = "blue")
|
||||
|
||||
## Note: We now at least C-c C-c {ess-eval-function-or-paragraph-and-step}
|
||||
|
||||
### --- 3 ----------------------------------------------------------------
|
||||
###--- This one (from the Matrix package) is for testing ess-roxy...,
|
||||
## i.e., C-c C-o
|
||||
|
||||
## not exported but used more than once for "dimnames<-" method :
|
||||
## -- or do only once for all "Matrix" classes ??
|
||||
dimnamesGets <- function (x, value) {
|
||||
d <- dim(x)
|
||||
if (!is.list(value) || length(value) != 2 ||
|
||||
!(is.null(v1 <- value[[1]]) || length(v1) == d[1]) ||
|
||||
!(is.null(v2 <- value[[2]]) || length(v2) == d[2]))
|
||||
stop(gettextf("invalid dimnames given for '%s' object", class(x)))
|
||||
x@Dimnames <- list(if(!is.null(v1)) as.character(v1),
|
||||
if(!is.null(v2)) as.character(v2))
|
||||
x
|
||||
}
|
||||
|
||||
### --- 4 ----------------------------------------------------------------
|
||||
### continued statements
|
||||
a <- function(ch) {
|
||||
if(ch == Inf) {
|
||||
E.cond <- numeric(nb)
|
||||
}
|
||||
else {
|
||||
indic <- ifelse(jinf+1 <= 1 & jsup >= 1,1,0)
|
||||
E.cond <- ch*(-pbinom(jinf,ni,prb) + 1-pbinom(js.n,ni,prb)) +
|
||||
ifelse(ni == 1, prb*indic,
|
||||
mu*(pbinom(js.n-1,pmax(ni-1,1),prb) -
|
||||
pbinom(jinf-1,pmax(ni-1,1),prb))) / sV -
|
||||
### ^-- now here (better)
|
||||
mu/sV*(pbinom(js.n,ni,prb) - pbinom(jinf,ni,prb))
|
||||
### ^-- now here (ok; more indentation would also be ok)
|
||||
indic2 <- ifelse(jinf+1 <= 1 & jsup >= 1 & ni == 2,1,0)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
### --- 5 ----------------------------------------------------------------
|
||||
### The beginning of function is not found correctly, and hence
|
||||
### all "ess-*-function" (C-M-a, C-M-e, ...) fail:
|
||||
|
||||
setMeneric <-
|
||||
## It is clearly allowed to have comments here.
|
||||
## S version 4, and John Chambers in particular like it.
|
||||
##
|
||||
## BUG: M-C-e or M-C-a fails from ``here'' --
|
||||
## --- effectively because of ess-beginning-of-function fails
|
||||
## and that really relies on finding ess-function-pattern;
|
||||
## i.e., ess-R-function-pattern in ~/emacs/ess/lisp/ess-cust.el
|
||||
##
|
||||
function(name, def = NULL, group = list(), valueClass = character(),
|
||||
where = topenv(parent.frame()), genericFunction = NULL)
|
||||
{
|
||||
## comments in here are at least kept via "source" attribute
|
||||
if(exists(name, "package:base") &&
|
||||
typeof(get(name, "package:base")) != "closure") {
|
||||
FALSE
|
||||
}
|
||||
"ABC"
|
||||
}
|
||||
|
||||
### --- 6 ----------------------------------------------------------------
|
||||
## In one-liners without "{ ... }" body, the end-of-function is also
|
||||
## not correctly found:
|
||||
## Use C-M-e to see: In these two, the "end-of-function" is after
|
||||
## 'class' :
|
||||
## ---- these all work now (ESS version 5.3.8) :
|
||||
## no it doesn't VS[10-03-2012|ESS 12.03]:
|
||||
onelinerFails <- function(x, ...) class(x)
|
||||
|
||||
onelinerFailsToo <-
|
||||
function(x, ...)
|
||||
class(x)
|
||||
|
||||
onelinerWorks <- function(x, ...) { class(x) }
|
||||
|
||||
onelinerWorksToo <-
|
||||
function(x, ...) {
|
||||
class(x)
|
||||
}
|
||||
|
||||
### --- 7 ----------------------------------------------------------------
|
||||
## idem:
|
||||
## this has one line more before 'function' than "typically:"
|
||||
setMethod("[", signature(x = "dgTMatrix", i = "numeric", j = "missing",
|
||||
drop = "logical"),
|
||||
function (x, i, j, ..., drop) { ## select rows
|
||||
storage.mode(i) <- "integer"
|
||||
xi <- x@i + 1:1 # 1-indexing
|
||||
## ...................
|
||||
if (drop && any(nd == 1)) drop(as(x,"matrix")) else x
|
||||
})
|
||||
|
||||
### --- 8 ----------------------------------------------------------------
|
||||
## idem:
|
||||
## all bellow are ok VS[10-03-2012|ESS 12.03]:
|
||||
"dimnames<-.data.frame" <- function(x, value) {
|
||||
d <- dim(x)
|
||||
if(!is.list(value) || length(value) != 2
|
||||
|| d[[1]] != length(value[[1]])
|
||||
|| d[[2]] != length(value[[2]]))
|
||||
stop("invalid 'dimnames' given for data frame")
|
||||
row.names(x) <- as.character(value[[1]]) # checks validity
|
||||
names(x) <- as.character(value[[2]])
|
||||
x
|
||||
}
|
||||
|
||||
'[.foo' <- function(x, i, value)
|
||||
{
|
||||
###
|
||||
y <- x
|
||||
y[i] <- value
|
||||
y
|
||||
}
|
||||
|
||||
'[[.bar' <- function(x, i, value)
|
||||
{
|
||||
## bla bla bla
|
||||
y <- as.foo(x) ; y[[i]] <- value
|
||||
y
|
||||
}
|
||||
|
||||
"[<-.foobar" <- function(x,i,j,value) {
|
||||
## just something
|
||||
x
|
||||
}
|
||||
|
||||
"names<-.foobar" <- function(x, value) {
|
||||
## just something else
|
||||
x
|
||||
}
|
||||
|
||||
`[<-.data.frame` <- function(x, i, j, value)
|
||||
{
|
||||
nA <- nargs() # value is never missing, so 3 or 4.
|
||||
|
||||
###..........
|
||||
|
||||
class(x) <- cl
|
||||
x
|
||||
}
|
||||
|
||||
"[[<-.data.frame"<- function(x, i, j, value)
|
||||
{
|
||||
cl <- oldClass(x)
|
||||
## delete class: Version 3 idiom
|
||||
## to avoid any special methods for [[<-
|
||||
class(x) <- NULL
|
||||
|
||||
###...........
|
||||
|
||||
class(x) <- cl
|
||||
x
|
||||
}
|
||||
|
||||
|
||||
"$<-.data.frame" <- function(x, i, value)
|
||||
{
|
||||
cl <- oldClass(x)
|
||||
## delete class: Version 3 idiom
|
||||
## to avoid any special methods for [[<-
|
||||
|
||||
###...........
|
||||
|
||||
class(x) <- cl
|
||||
return(x)
|
||||
}
|
||||
|
||||
## swanky functions:
|
||||
`swank:quit-inspector` <- function(slimeConnection, sldbState) {
|
||||
resetInspector(slimeConnection)
|
||||
FALSE
|
||||
}
|
||||
|
||||
'swank:quit-inspector' <- function(slimeConnection, sldbState) {
|
||||
resetInspector(slimeConnection)
|
||||
FALSE
|
||||
}
|
||||
|
||||
|
||||
### --- 9 ----------------------------------------------------------------
|
||||
## VS[03-2012|12.03]:FIXED:
|
||||
|
||||
## From: "Sebastian P. Luque" <spluque@gmail.com>
|
||||
## To: ess-bugs@stat.math.ethz.ch
|
||||
## Subject: [ESS-bugs] ess-mode 5.12; `ess-indent-line' error
|
||||
## Date: Tue, 17 Aug 2010 13:08:25 -0500
|
||||
|
||||
## With the following input, and point on the line with "Table 8.3":
|
||||
## it was the parenthetical expression at the beg of line
|
||||
|
||||
if (require(lme4)) {
|
||||
## Model in p. 213
|
||||
(fm1 <- lmer(logFEV1 ~ age + log(height) + age0 + log(height0) + (age | id),
|
||||
data=fev1, subset=logFEV1 > -0.5))
|
||||
## Table 8.3
|
||||
VarCorr(fm1)$id * 100
|
||||
|
||||
## Model in p. 216
|
||||
(fm2 <- update(fm1, . ~ . - (age | id) + (log(height) | id)))
|
||||
}
|
||||
|
||||
### -----
|
||||
## hitting TAB (`ess-indent-command'), which calls `ess-indent-line' I get
|
||||
## the following trace:
|
||||
|
||||
## ....: (scan-error "Containing expression ends prematurely" 20 20)
|
||||
## scan-sexps(177 -2)
|
||||
## forward-sexp(-2)
|
||||
## ...
|
||||
## ess-continued-statement-p()
|
||||
## ......
|
||||
|
||||
## Interestingly, if the lines 2-4 are absent, then the problem is gone.
|
||||
## The problem is also there in ESS 5.11.
|
||||
|
||||
## I'll try to find out what is going on in `ess-continued-statement-p' but
|
||||
## given that I'm not very familiar with the stuff in ess-mode.el, I'm
|
||||
## submitting the report in case somebody can detect the issue sooner.
|
||||
|
||||
## another example: hitting Tab at }else line
|
||||
.essDev_differs <- function(f1, f2){
|
||||
if (is.function(f1) && is.function(f2)){
|
||||
!(identical(body(f1), body(f2)) && identical(args(f1), args(f2)))
|
||||
}else
|
||||
!identical(f1, f2)
|
||||
}
|
||||
|
||||
|
||||
|
||||
### --- 10 ---------------------------------------------------------------
|
||||
## indent at 0 after }else:
|
||||
## VS:[03-2012|12.03]:FIXED:
|
||||
if (is.function(f1) && is.function(f2)){
|
||||
!(identical(body(f1), body(f2)) && identical(args(f1), args(f2)))
|
||||
}else
|
||||
!identical(f1, f2)
|
||||
|
||||
|
||||
### --- 11 ---------------------------------------------------------------
|
||||
## --------------- C-c C-c was finding the wrong "beginning of function"
|
||||
## [:FIXED:, 2011-05-28]
|
||||
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))
|
||||
|
||||
### --- 12 ---------------------------------------------------------------
|
||||
##--- In the following block, in the first line, C-c C-c does *NOT* behave
|
||||
## VS[10-03-2012|ESS 12.03]: works fine for me:
|
||||
th <- 48 # now do ls() and see what happened ... the horror !!!
|
||||
d <- 3
|
||||
cpF <- list("Frank", list(th, 1:d))
|
||||
cop <- acF <- cpF$copula
|
||||
|
||||
### --- 13 ---------------------------------------------------------------
|
||||
## VS[05-05-2012|ESS 12.04]: looks like :FIXED:
|
||||
|
||||
## From: Aleksandar Blagotic <aca.blagotic@gmail.com>
|
||||
## To: <ess-help@stat.math.ethz.ch>
|
||||
## Subject: [ESS] R-mode: forward-sexp: Scan error: "Unbalanced parentheses"
|
||||
## Date: Tue, 6 Dec 2011 01:24:11 +0100
|
||||
#
|
||||
## Let's presuppose that I have a function like this:
|
||||
#
|
||||
fn <- function(x, ...){
|
||||
re <- "^#{1,6} [[:print:]]+$"
|
||||
grepl(re, x, ...)
|
||||
}
|
||||
## As soon as I put my cursor at the end of the line with regexp, and
|
||||
## press RET, I get this error:
|
||||
|
||||
## forward-sexp: Scan error: "Unbalanced parentheses"
|
||||
##
|
||||
##-------
|
||||
## Rodney S: I can reproduce it ...
|
||||
## Martin M: I can NOT reproduce it, neither with 'emacs -Q';
|
||||
## tried both ESS 5.14 and ESS from svn
|
||||
## VS[03-2012|12.03]: Cannot reproduce it either, solved?
|
||||
|
||||
|
||||
### --- 14 ---------------------------------------------------------------
|
||||
## check the behavior of ess-arg-function-offset-new-line
|
||||
|
||||
a <- some.function(
|
||||
arg1,
|
||||
arg2)
|
||||
## ^--- RRR has ess-arg-function-offset-new-line (4) ==> should indent here
|
||||
|
||||
a <- some.function(arg1,
|
||||
arg2)
|
||||
## ^--- here
|
||||
|
||||
|
||||
### --- 15 --------------------------------------------------------------
|
||||
## VS[05-05-2012|ESS 12.04]:FIXED:
|
||||
## indentation of the 3rd line is wrong
|
||||
for(s in seq(10, 50, len = 5))
|
||||
for(a in seq(.5, 1, len = 5))
|
||||
pt_dif_plot(s, a)
|
||||
## ^-- here
|
||||
|
||||
### --- 16 ----
|
||||
## VS[05-05-2012|ESS 12.04]:FIXED:
|
||||
## MM[2014-04-28]: added '}' before else (=> "{" after if(.))
|
||||
## so parse(<file>) works at all!
|
||||
## Gives error unbalanced para at else lines and indentation is wrong
|
||||
## error: Point is not in a function according to 'ess-function-pattern'.
|
||||
getOrCreateForm <- function(bindName, whereEnv)
|
||||
if(exists(bindName, envir = get(".forms", envir = whereEnv))) {
|
||||
get(bindName, envir = whereEnv)
|
||||
### ^-- here
|
||||
} else
|
||||
new("protoForm")
|
||||
### ^-- here
|
||||
|
||||
|
||||
|
||||
parentContainer <-
|
||||
if(is.null(.getPrototype(.Object@host))) { emptyenv()
|
||||
} else sdf
|
||||
### ^-- here
|
||||
|
||||
parentContainer <-
|
||||
if(is.null(.getPrototype(.Object@host))) emptyenv()
|
||||
else sdf
|
||||
### ^-- here
|
||||
|
||||
### --- 17 ---
|
||||
## Indentation ----- "expression" is special
|
||||
expremmion <- c(1, 3,
|
||||
9876)# was always ok
|
||||
## Had wrong indentation here:
|
||||
expression <- c(2343,
|
||||
23874, 239487)
|
||||
|
||||
## or here:
|
||||
foo <- function(x) {
|
||||
expression <- c(2343,
|
||||
23874, 239487)
|
||||
10 + expression
|
||||
}
|
||||
|
||||
## Where as here, we *do* want the indentation to
|
||||
## *NOT* go all the way to the right:
|
||||
|
||||
{
|
||||
my.long.Expression <- expression(
|
||||
x[a[j]] == exp(theta[1] + theta[2]^2),
|
||||
x[b[i]] == sin(theta[3] ~~ theta[4])
|
||||
)
|
||||
ausdruck <- expression
|
||||
my.long.Expr...... <- ausdruck(
|
||||
x[a[j]] == exp(theta[1] + theta[2]^2),
|
||||
)
|
||||
}
|
||||
|
||||
## VS[18-08-2012]: redundant feature. This is a feature for long subexpressions
|
||||
## imidiately folowing new line. Documented in ess-arg-function-offset-new-line
|
||||
|
||||
### --- 18 ---
|
||||
## M-C-a (beginning of function)
|
||||
## ----- anywhere inside the following function, M-C-a must go to beginning
|
||||
Ops.x.x <- function(e1, e2)
|
||||
{
|
||||
d <- dimCheck(e1,e2)
|
||||
if((dens1 <- extends(c1 <- class(e1), "denseMatrix")))
|
||||
gen1 <- extends(c1, "generalMatrix")
|
||||
if((dens2 <- extends(c2 <- class(e2), "denseMatrix")))
|
||||
gen2 <- extends(c2, "generalMatrix")
|
||||
if(dens1 && dens2) { ## both inherit from ddense*
|
||||
geM <- TRUE
|
||||
if(!gen1) {
|
||||
if(!gen2) { ## consider preserving "triangular" / "symmetric"
|
||||
geM <- FALSE
|
||||
le <- prod(d)
|
||||
isPacked <- function(x) length(x@x) < le
|
||||
}
|
||||
}
|
||||
## now, in all cases @x should be matching & correct {only "uplo" part is used}
|
||||
r <- callGeneric(e1@x, e2@x)
|
||||
if(geM)
|
||||
new(paste0(.M.kind(r), "geMatrix"), x = r, Dim = d, Dimnames = dimnames(e1))
|
||||
else
|
||||
new(paste0(.M.kind(r), Mclass), x = r, Dim = d, .....)
|
||||
}
|
||||
else {
|
||||
r <- ....
|
||||
|
||||
## criterion "2 * nnz(.) < ." as in sparseDefault() in Matrix() [./Matrix.R] :
|
||||
if(2 * nnzero(r, na.counted = TRUE) < prod(d))
|
||||
as(r, "sparseMatrix") else r
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
### --- 19 ---
|
||||
## indentation with regexp (bug in ess-backward-to-noncomment)
|
||||
parse_roc <- function(lines, match = "^\\s*+\' ?") {
|
||||
lines <- lines[str_detect(lines, match)]
|
||||
if (length(lines) == 0) return(NULL)
|
||||
### ^-- here (2014-11: fixed)
|
||||
}
|
||||
|
||||
|
||||
### --- 20 ---
|
||||
## continuation indentation must be consistent in/out {}:
|
||||
|
||||
{
|
||||
a <- ggplot(data = overtime.by.month,
|
||||
aes(x="", y=Percent, fill = Overtime)) +
|
||||
geom_bar(width = 1) +
|
||||
xlab('') +
|
||||
ylab(sub.txt) +
|
||||
labs(title = title.txt) +
|
||||
facet_wrap(~Year.Month)
|
||||
}
|
||||
|
||||
a <- ggplot(data = overtime.by.month,
|
||||
aes(x="", y=Percent, fill = Overtime)) +
|
||||
geom_bar(width = 1) +
|
||||
xlab('') +
|
||||
ylab(sub.txt) +
|
||||
labs(title = title.txt) +
|
||||
facet_wrap(~Year.Month)
|
||||
### ^-- face_wrap must be here
|
||||
|
||||
|
||||
### --- 20b ---
|
||||
## From https://github.com/emacs-ess/ESS/issues/120
|
||||
|
||||
mean(rnorm(100, mean = runif(1, 1, 10)), na.rm =TRUE) +
|
||||
2
|
||||
## ^--- 2 is here
|
||||
|
||||
mean(rnorm(100, mean = runif(1, 1, 10)),
|
||||
na.rm =TRUE) +
|
||||
2
|
||||
## ^--- 2 is here
|
||||
|
||||
mean(rnorm(100,
|
||||
mean = runif(1, 1, 10)), na.rm=TRUE) +
|
||||
2
|
||||
## ^--- 2 is here
|
||||
|
||||
### --- 21 ---
|
||||
|
||||
## From: Marius Hofert <marius.hofert@math.ethz.ch>
|
||||
## Date: Fri, 15 Mar 2013 21:00:45 +0100
|
||||
## Hi,
|
||||
## The following bug happens in ESS 12.09-2 [rev. 5395 (2013-01-10)]. Put the
|
||||
## cursor in the line before the function head and hit C-c C-c.
|
||||
|
||||
foo <- function(x)
|
||||
x # bar
|
||||
x <- 1:10
|
||||
|
||||
## I'll see
|
||||
## > + > [1] 1 2 3 4 5 6 7 8 9 10
|
||||
## ESS 15.03: Error in eval(expr, .... : object 'x' not found
|
||||
|
||||
foo <- function(x) x*x
|
||||
bar <- function(y) y
|
||||
## via C-c C-c leads to "Error: object 'bar' not found". -- fixed
|
||||
|
||||
|
||||
### --- 22 ----
|
||||
## now correct indentation (inspite of # {was same reason as 19})
|
||||
if (!grepl("#", x))
|
||||
return(res)
|
||||
|
||||
### --- 23 ----
|
||||
### three ways to indent closing parent depending on context:
|
||||
foo <-
|
||||
function_call(
|
||||
a,
|
||||
b,
|
||||
c
|
||||
)
|
||||
### ^-- ) is here now
|
||||
|
||||
foo <- function_call(
|
||||
a,
|
||||
b,
|
||||
c
|
||||
)
|
||||
### ")" is at column 0
|
||||
|
||||
foo <- function_call(a,
|
||||
b,
|
||||
c
|
||||
)
|
||||
### ^-- ) is here
|
||||
|
||||
### --- 24 ---
|
||||
### shift comma in function calls
|
||||
|
||||
foo <- function_call(a
|
||||
, b
|
||||
, c
|
||||
### ^-- c is here
|
||||
)
|
||||
### ^-- ) is here
|
||||
|
||||
### --- 25 ---
|
||||
## if/else in function calls and nested
|
||||
|
||||
function_call(abc =
|
||||
if (test)
|
||||
do_something
|
||||
else
|
||||
do_something_else)
|
||||
|
||||
function_call(
|
||||
abc =
|
||||
if (test)
|
||||
do_something
|
||||
else
|
||||
do_something_else)
|
||||
|
||||
|
||||
function_call(abc = if (test)
|
||||
do_something
|
||||
else
|
||||
do_something_else)
|
||||
|
||||
## real example is smooth.spline() source code [still (2015-04-08) wrong / bug!]
|
||||
ss <- function (x, all.knots, nknots, ...)
|
||||
{
|
||||
if (all.knots) {
|
||||
if (!missing(nknots) && !is.null(nknots))
|
||||
warning("'all.knots' is TRUE; 'nknots' specification is disregarded")
|
||||
nknots <- nx
|
||||
} else if (is.null(nknots)) # <- for back compatibility
|
||||
nknots <- .nknots.smspl(nx)
|
||||
else {
|
||||
### ^ want 'else' there
|
||||
if (is.function(nknots))
|
||||
nknots <- nknots(nx)
|
||||
else if (!is.numeric(nknots))
|
||||
stop("'nknots' must be numeric (in {1,..,n})")
|
||||
if (nknots < 1)
|
||||
stop("'nknots' must be at least 1")
|
||||
else if (nknots > nx)
|
||||
stop("cannot use more inner knots than unique 'x' values")
|
||||
}
|
||||
### ^-- want '}' there
|
||||
}
|
||||
|
||||
## "if" conditional is an exception of the continuation rules:
|
||||
## Here, we do not want subsequently further indentation of the c1 || c2 || c3
|
||||
## part:
|
||||
t2 <- function(x) {
|
||||
if(long.expression.of.some.size(x, pi) ||
|
||||
another.longish.expression(sin(x)*exp(x)) ||
|
||||
a.third.condition.under.which.A.is.chosen)
|
||||
### ^-- here
|
||||
A
|
||||
else
|
||||
B
|
||||
}
|
||||
|
||||
|
||||
r <-
|
||||
(some.function (x, 2342) +
|
||||
another.f (x^3) + sdfsdf - sdfsdf +
|
||||
and(x) + the(x) - last(x)*part(3))
|
||||
|
||||
|
||||
### --- 26 ----
|
||||
## This is formally correct R, though help(parse) mentions the line-length limit of
|
||||
## 4095 __when reading from the console__
|
||||
## ESS gives syntax errors ("Error: unexpected ','" ...) when evaluating this
|
||||
## because line length >= 4096 :
|
||||
##
|
||||
x <- c(1, 3.075819, 1.515999, 2.156169, 1.480742, 1.765485, 1.460206, 1.603707, 1.427429, 1.504712, 1.334528, 1.48297, 1.355308, 1.383867, 1.319241, 1.36065, 1.307467, 1.365596, 1.255259, 1.352741, 1.239381, 3.15342, 1.799889, 2.258497, 1.688312, 1.906779, 1.548203, 1.724785, 1.500873, 1.573442, 1.417137, 1.540805, 1.395945, 1.472596, 1.394247, 1.377487, 1.337394, 1.369354, 1.333378, 1.3181, 1.313813, 1.315528, 2.12777, 2.718898, 1.993509, 2.220433, 1.820585, 1.97782, 1.672455, 1.770151, 1.587478, 1.685352, 1.539295, 1.584536, 1.499487, 1.50702, 1.41952, 1.449058, 1.393042, 1.432999, 1.369964, 1.400997, 1.333824, 2.950549, 2.145387, 2.382224, 1.927077, 2.032489, 1.8371, 1.877833, 1.710891, 1.756053, 1.620778, 1.657761, 1.558978, 1.56257, 1.508633, 1.534406, 1.46709, 1.468734, 1.432529, 1.455283, 1.386975, 1.417532, 2.229573, 2.494447, 2.016117, 2.190061, 1.877996, 1.978964, 1.767284, 1.836948, 1.677372, 1.743316, 1.616383, 1.655964, 1.55484, 1.594831, 1.502185, 1.543723, 1.467005, 1.491123, 1.44402, 1.446915, 1.401578, 2.580264, 2.109121, 2.240741, 1.944719, 2.043397, 1.821808, 1.89725, 1.748788, 1.786988, 1.659333, 1.697012, 1.610622, 1.616503, 1.538529, 1.562024, 1.499964, 1.529344, 1.474519, 1.483264, 1.441552, 1.434448, 2.165233, 2.320281, 2.007836, 2.086471, 1.884052, 1.950563, 1.76926, 1.843328, 1.708941, 1.741039, 1.627206, 1.644755, 1.580563, 1.593402, 1.527312, 1.568418, 1.501462, 1.502542, 1.464583, 1.467921, 1.431141, 2.340443, 2.048262, 2.161097, 1.926082, 1.995422, 1.81446, 1.853165, 1.738533, 1.784456, 1.679444, 1.696463, 1.612931, 1.629483, 1.548186, 1.580026, 1.52198, 1.531111, 1.482914, 1.484824, 1.442726, 1.447838, 2.093386, 2.185793, 1.948989, 2.02804, 1.867137, 1.907732, 1.771923, 1.800413, 1.691612, 1.720603, 1.642705, 1.649769, 1.589028, 1.598955, 1.539759, 1.55096, 1.503965, 1.50703, 1.471349, 1.469791, 1.436959, 2.218315, 1.997369, 2.041128, 1.887059, 1.928524, 1.79626, 1.827538, 1.716748, 1.735696, 1.658329, 1.664211, 1.599286, 1.611511, 1.553925, 1.562637, 1.516805, 1.529894, 1.476064, 1.482474, 1.453253, 1.458467, 2.0247, 2.07899, 1.921976, 1.949376, 1.824629, 1.851671, 1.744713, 1.765647, 1.683525, 1.685592, 1.625113, 1.624961, 1.571921, 1.581223, 1.535257, 1.537464, 1.497165, 1.504879, 1.468682, 1.469319, 1.448344, 2.092315, 1.941412, 1.969843, 1.844093, 1.866133, 1.766145, 1.783829, 1.703613, 1.709714, 1.646078, 1.654264, 1.594523, 1.598488, 1.545105, 1.555356, 1.514627, 1.521353, 1.483958, 1.487677, 1.449191, 1.459721, 1.958987, 1.985144, 1.87739, 1.879643, 1.786823, 1.799642, 1.720015, 1.724688, 1.663539, 1.662997, 1.609267, 1.615124, 1.56746, 1.562026, 1.520586, 1.52503, 1.493008, 1.502496, 1.471983, 1.468546, 1.435064, 1.994706, 1.880348, 1.894254, 1.805827, 1.815965, 1.744296, 1.743389, 1.665481, 1.681644, 1.624466, 1.626109, 1.584028, 1.5818, 1.54376, 1.547237, 1.504878, 1.515087, 1.479032, 1.47936, 1.450758, 1.45073, 1.892685, 1.91087, 1.825301, 1.827176, 1.745363, 1.746115, 1.693373, 1.701692, 1.648247, 1.637112, 1.594648, 1.592013, 1.554849, 1.55013, 1.522186, 1.520901, 1.492606, 1.493072, 1.460868, 1.46733, 1.440956, 1.92771, 1.835696, 1.841979, 1.775991, 1.766092, 1.703807, 1.708791, 1.654985, 1.655917, 1.602388, 1.611867, 1.570765, 1.573368, 1.53419, 1.529033, 1.506767, 1.503596, 1.481126, 1.471806, 1.444917, 1.451682, 1.850262, 1.855034, 1.778997, 1.789995, 1.718871, 1.717326, 1.667357, 1.666291, 1.619743, 1.631475, 1.582624, 1.58766, 1.546302, 1.545063, 1.512222, 1.517888, 1.489127, 1.487271, 1.466722, 1.463618, 1.444137, 1.8709, 1.794033, 1.80121, 1.736376, 1.740201, 1.673776, 1.682541, 1.638153, 1.642294, 1.604417, 1.597721, 1.559534, 1.559108, 1.533942, 1.529348, 1.499517, 1.501586, 1.473147, 1.473031, 1.457615, 1.452348, 1.805753, 1.812952, 1.746549, 1.747222, 1.696924, 1.694957, 1.652157, 1.650568, 1.607807, 1.613666, 1.577295, 1.570712, 1.543704, 1.538272, 1.515369, 1.517113, 1.487451, 1.491593, 1.464514, 1.464658, 1.439359, 1.823222, 1.758781, 1.767358, 1.70872, 1.712926, 1.666956, 1.667838, 1.62077, 1.621445, 1.592891, 1.58549, 1.55603, 1.559042, 1.521501, 1.523342, 2, 3, 4)
|
||||
|
||||
### --- 27 ----
|
||||
## Indentation after open brace
|
||||
.a.lst <-
|
||||
list(ex1 = function(p) {
|
||||
cMah <- qchisq(0.975, p)
|
||||
function(d) as.numeric(d < cMah)
|
||||
### ^--- now here (less indented than prev.)
|
||||
},
|
||||
ex2 = function(p) {
|
||||
cM <- qchisq(0.95, p)
|
||||
function(d) as.numeric(d < cM)
|
||||
### ^--- here
|
||||
})
|
||||
### ^--- '}' here
|
||||
|
||||
|
||||
.a.lst <- list(ex1 = function(p) {
|
||||
cMah <- qchisq(0.975, p)
|
||||
function(d) as.numeric(d < cMah)
|
||||
}, ## <- now at column 0 {also the next line}
|
||||
ex2 = function(p) {
|
||||
cM <- qchisq(0.95, p)
|
||||
function(d) as.numeric(d < cM)
|
||||
})
|
||||
|
||||
|
||||
.a.lst <- list(list(aa = {
|
||||
bbb
|
||||
### ^--- here
|
||||
},
|
||||
aaa = function(p) {
|
||||
qchisq(0.95, p)
|
||||
### ^--- here
|
||||
},
|
||||
aaaa = {
|
||||
cccc
|
||||
### ^--- here
|
||||
}))
|
||||
|
||||
list(function(p){
|
||||
abc
|
||||
### ^-- here
|
||||
})
|
||||
### at column 0
|
||||
|
||||
(ab) {
|
||||
sfdsf
|
||||
### ^-- here
|
||||
}
|
||||
|
||||
### --- 27b --- [new, 2015-04-09]
|
||||
print.MethodsFunction <- function(x, byclass = attr(x, "byclass"), ...)
|
||||
{
|
||||
info <- attr(x, "info")
|
||||
values <- if (byclass) {
|
||||
unique(info$generic)
|
||||
} else {
|
||||
visible <- ifelse(info$visible, "", "*")
|
||||
paste0(rownames(info), visible)
|
||||
### ^-- both lines above should start here
|
||||
}
|
||||
### ^-- "}" here
|
||||
|
||||
## 2nd version:
|
||||
val <-
|
||||
if (byclass) {
|
||||
unique(info$generic)
|
||||
} else {
|
||||
visible <- ifelse(info$visible, "", "*")
|
||||
paste0(rownames(info), visible)
|
||||
### ^-- both lines above should start here
|
||||
}
|
||||
### ^-- "}" here
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
|
||||
|
||||
### --- 28 --- [2015-02-17; still unfixed, 2015-11-21]
|
||||
## Indentation of end-line comments (to column 40 = 'indent-column')
|
||||
## {this is part of "real" code in Rmpfr/R/hjk.R}:
|
||||
hjk <- function(x,n) { # <--- C-M-q "on {" -- does *no longer* indent the "# .."
|
||||
##-- Setting steps and stepsize -----
|
||||
nsteps <- floor(log2(1/tol)) # number of steps
|
||||
steps <- 2^c(-(0:(nsteps-1))) # decreasing step size
|
||||
dir <- diag(1, n, n) # orthogonal directions
|
||||
|
||||
x <- par # start point
|
||||
fx <- f(x) # smallest value so far
|
||||
fcount <- 1 # counts number of function calls
|
||||
|
||||
if (info) cat(sprintf("step nofc %-12s | %20s\n",
|
||||
"fmin", "xpar"))
|
||||
|
||||
##-- Start the main loop ------------
|
||||
ns <- 0
|
||||
while (ns < nsteps && fcount < maxfeval && abs(fx) < target) {
|
||||
ns <- ns + 1
|
||||
hjs <- .hjsearch(x, f, steps[ns], dir, fcount, maxfeval, target)
|
||||
}
|
||||
hjs
|
||||
}
|
||||
|
||||
### --- 29 ---
|
||||
foreach(a = 1:3) %do% {
|
||||
a^2
|
||||
### ^--- here
|
||||
}
|
||||
|
||||
foreach(a = 1:3) %:%
|
||||
foreach(b = 10:13) %dopar% {
|
||||
### ^--- here
|
||||
a + b
|
||||
### ^---- here
|
||||
}
|
||||
### ^--- here
|
||||
|
||||
read.csv('file.csv') %>%
|
||||
mutate(X = X+2, Y = Y/2) %>%
|
||||
### ^--- here
|
||||
filter(X < 5)
|
||||
### ^-- here (*was* indented earlier)
|
||||
|
||||
|
||||
### --- 30 ---
|
||||
## a) ok:
|
||||
{
|
||||
r <- array(if (d[3L] == 3L)
|
||||
rgb(t(x[,,1L]), t(x[,,2L]), t(x[,,3L]), maxColorValue = max)
|
||||
else if (d[3L] == 4L)
|
||||
rgb(t(x[,,1L]), t(x[,,2L]), t(x[,,3L]), t(x[,,4L]), maxColorValue = max)
|
||||
else stop("foo"),
|
||||
dim = d[1:2])
|
||||
}
|
||||
|
||||
## b) ok :
|
||||
{
|
||||
obj <- obj && (condition1 || class2 %in% .BasicClasses ||
|
||||
condition3)
|
||||
}
|
||||
|
||||
## c) ok:
|
||||
{
|
||||
if (any(abs(d) < .001*abs(dd) |
|
||||
(is.na(d) & x == y)))
|
||||
TRUE
|
||||
}
|
||||
|
||||
|
||||
### --- 31 --------
|
||||
## C-s "recog"; M-C-a -- should go to beginning of function, does not
|
||||
|
||||
glmmTMB <- function (formula, data = NULL)
|
||||
{
|
||||
## glFormula <- function(formula, data=NULL, family = gaussian,
|
||||
## subset, weights, na.action, offset,
|
||||
## contrasts = NULL, mustart, etastart,
|
||||
## control = glmerControl(), ...) {
|
||||
|
||||
## FIXME: check for offsets in ziformula/dispformula, throw an error
|
||||
|
||||
call <- mf <- mc <- match.call()
|
||||
|
||||
if (is.null(family$family)) {
|
||||
print(family)
|
||||
stop("'family' not recognized")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
### --- 32 --- 2015-11-07 --- indentation again! --------
|
||||
{
|
||||
yl <- if(strictlim) {
|
||||
ylim
|
||||
}
|
||||
else {
|
||||
range(y, ylim)
|
||||
}
|
||||
## room below for weights
|
||||
dy <- 4*dy
|
||||
}
|
||||
## -- 32 b)
|
||||
{
|
||||
yl <- if(strictlim) {
|
||||
ylim
|
||||
}
|
||||
else
|
||||
range(y, ylim)
|
||||
## continue
|
||||
}
|
||||
## -- 32 c)
|
||||
{
|
||||
U <- if(is.matrix(x))
|
||||
apply(x, 2, foo) / (nrow(x) + 1)
|
||||
else
|
||||
foo(x) / (length(x) + 1)
|
||||
}
|
||||
## 'else' now aligns with 'if' (and their code too)
|
||||
|
||||
### --- 33 -- Treat `<<-` as `<-`
|
||||
{
|
||||
f(X <-
|
||||
callme(arg))
|
||||
f(X <<-
|
||||
callme(arg))
|
||||
}
|
||||
## the 2nd callme() now indents like the first
|
||||
|
||||
|
||||
### Local Variables:
|
||||
### page-delimiter: "^### --- [1-9]"
|
||||
### End:
|
91
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.el
Normal file
91
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.el
Normal file
@@ -0,0 +1,91 @@
|
||||
;;;; Things that go wrong or *went* wrong in the past
|
||||
;;;; (from list side) see R-ESS-bugs.R for the R's side.
|
||||
|
||||
|
||||
;;;; 1 ess-get-words-from-vector stumbles over \"
|
||||
(ess-get-words-from-vector "c('aaa','bbb\"ccc', 'dddd')\n")
|
||||
;;-> (" " "ccc" "dddd"): SOLVED
|
||||
|
||||
|
||||
;;;; 2 ess-get-words-from-vector disregards max.print
|
||||
;; options(max.print=1000) (warning added to the docs)
|
||||
(length (ess-get-words-from-vector "as.character(1:10000)\n"))
|
||||
;;-> 1001 with "max.print" at the end; added a comment in the function doc
|
||||
|
||||
;;;; 3 Inferior-ess-primary-prompt does not capture "+ + > "
|
||||
;; this hangs emacs; SOLVED
|
||||
(ess-command "tf<-function(N){
|
||||
N}\n")
|
||||
|
||||
;;;; 4 ess-command detects the prompt prematurely
|
||||
;; this outputs str(iris) in the inferior buffer; SOLVED
|
||||
(ess-command "
|
||||
lm_test <- function (formula, data, subset, weights, na.action, method = 'qr',
|
||||
model = TRUE, x = FALSE, y = FALSE, qr = TRUE, singular.ok = TRUE,
|
||||
contrasts = NULL, offset, ...)
|
||||
{
|
||||
cl <- match.call()
|
||||
mf <- match.call(expand.dots = FALSE)
|
||||
m <- match(c('formula', 'data', 'subset', 'weights', 'na.action',
|
||||
'offset'), names(mf), 0L)
|
||||
mf <- mf[c(1L, m)]
|
||||
mf$drop.unused.levels <- TRUE
|
||||
mf[[1L]] <- as.name('model.frame')
|
||||
mf <- eval(mf, parent.frame())
|
||||
if (method == 'model.frame')
|
||||
return(mf)
|
||||
else if (method != 'qr')
|
||||
warning(gettextf('method is not supported. Using',
|
||||
method), domain = NA)
|
||||
mt <- attr(mf, 'terms')
|
||||
y <- model.response(mf, 'numeric')
|
||||
w <- as.vector(model.weights(mf))
|
||||
if (!is.null(w) && !is.numeric(w))
|
||||
stop('weights must be a numeric vector')
|
||||
offset <- as.vector(model.offset(mf))
|
||||
if (!is.null(offset)) {
|
||||
if (length(offset) != NROW(y))
|
||||
stop(gettextf('number of offsets is %d, should equal %d (number of observations)',
|
||||
length(offset), NROW(y)), domain = NA)
|
||||
}
|
||||
if (is.empty.model(mt)) {
|
||||
x <- NULL
|
||||
z <- list(coefficients = if (is.matrix(y)) matrix(, 0,
|
||||
3) else numeric(0L), residuals = y, fitted.values = 0 *
|
||||
y, weights = w, rank = 0L, df.residual = if (!is.null(w)) sum(w !=
|
||||
0) else if (is.matrix(y)) nrow(y) else length(y))
|
||||
if (!is.null(offset)) {
|
||||
z$fitted.values <- offset
|
||||
z$residuals <- y - offset
|
||||
}
|
||||
}
|
||||
else {
|
||||
x <- model.matrix(mt, mf, contrasts)
|
||||
z <- if (is.null(w))
|
||||
lm.fit(x, y, offset = offset, singular.ok = singular.ok,
|
||||
...)
|
||||
else lm.wfit(x, y, w, offset = offset, singular.ok = singular.ok,
|
||||
...)
|
||||
}
|
||||
class(z) <- c(if (is.matrix(y)) 'mlm', 'lm')
|
||||
z$na.action <- attr(mf, 'na.action')
|
||||
z$offset <- offset
|
||||
z$contrasts <- attr(x, 'contrasts')
|
||||
z$xlevels <- .getXlevels(mt, mf)
|
||||
z$call <- cl
|
||||
z$terms <- mt
|
||||
if (model)
|
||||
z$model <- mf
|
||||
if (ret.x)
|
||||
z$x <- x
|
||||
if (ret.y)
|
||||
z$y <- y
|
||||
if (!qr)
|
||||
z$qr <- NULL
|
||||
z
|
||||
}
|
||||
str(iris)
|
||||
")
|
||||
|
||||
;;;; 5 double prompt > > used to stall emacs; SOLVED
|
||||
(ess-command "\n\n\n")
|
BIN
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.elc
Normal file
BIN
.emacs.d/elpa/ess-20160208.453/etc/R-ESS-bugs.elc
Normal file
Binary file not shown.
24
.emacs.d/elpa/ess-20160208.453/etc/R-oxygen-ex.R
Normal file
24
.emacs.d/elpa/ess-20160208.453/etc/R-oxygen-ex.R
Normal file
@@ -0,0 +1,24 @@
|
||||
### Go inside the "preamble" section and type C-e C-e C-r (ess-roxy-preview-Rd)
|
||||
### to get an R error message about 'col(m)' --> there's a buglet somewhere
|
||||
|
||||
##' Computes different parameter estimates for foo bars and variations
|
||||
##'
|
||||
##' @title Estimation procedures for Foo Bar
|
||||
##' @param x data matrix
|
||||
##' @param op object to be estimated
|
||||
##' @param method estimation method; can be
|
||||
##' "mle" MLE
|
||||
##' "smle" SMLE
|
||||
##' "dmle" MLE based on the diagonal
|
||||
##' "mde.normal" minimum distance estimation based on the chisq distribution and CvM distance
|
||||
##' "mde.log" minimum distance estimation based on the Erlang distribution and CvM distance
|
||||
##' "tau.tau.mean" averaged pairwise Kendall's tau estimator
|
||||
##' "tau.theta.mean" average of Kendall's tau estimators
|
||||
##' "beta" multivariate Blomqvist's beta estimator
|
||||
##' @return estimated value/vector according to the chosen method
|
||||
##' @author Foo Bar
|
||||
estimateFoo <- function(x, op, method=c("mle", "smle", "dmle", "mde.normal", "mde.log",
|
||||
"tau.tau.mean", "tau.theta.mean", "beta"))
|
||||
{
|
||||
....
|
||||
}
|
18
.emacs.d/elpa/ess-20160208.453/etc/R-pager.R
Normal file
18
.emacs.d/elpa/ess-20160208.453/etc/R-pager.R
Normal file
@@ -0,0 +1,18 @@
|
||||
mypager <- function(files, header, title, delete.file) {
|
||||
tfile <- tempfile(paste(basename(files[1]),"__", sep=""))
|
||||
Tf <- file(tfile, open="w+")
|
||||
stopifnot(file.append(tfile, files))
|
||||
system(paste("emacsclient -n", tfile))
|
||||
}
|
||||
file.show(file.path(R.home("doc"), "COPYRIGHTS"),
|
||||
pager = mypager)
|
||||
|
||||
options(pager = mypager)
|
||||
|
||||
|
||||
## test :
|
||||
file.show(file.path(R.home("doc"), "COPYRIGHTS"))
|
||||
|
||||
## or
|
||||
RShowDoc('NEWS')
|
||||
## using a suboptimal file name
|
60
.emacs.d/elpa/ess-20160208.453/etc/R_error_patterns.R
Normal file
60
.emacs.d/elpa/ess-20160208.453/etc/R_error_patterns.R
Normal file
@@ -0,0 +1,60 @@
|
||||
|
||||
## 1
|
||||
Error: chunk 7 (label = OP4)
|
||||
Error in disp.Rnw:656:31: unexpected symbol
|
||||
655: par(mgp = c(2.5, 1, 1), mar = c(0, 0, 0, 0),
|
||||
656: plt= c(0.08, 0.9, 0.25, 0.p9
|
||||
|
||||
))
|
||||
|
||||
## 2
|
||||
Browse[2]> Error in x %*% y (from models.R#46) :
|
||||
Cholmod error 'X and/or Y have wrong dimensions' at file ../MatrixOps/cholmod_sdmult.c, line 90
|
||||
|
||||
|
||||
## 3
|
||||
Error in source("~/works/protoClasses/R/funcs.R") (from hierarchy.R#6) :
|
||||
~/works/protoClasses/R/funcs.R:1797:5: unexpected '[['
|
||||
1796: b[[2]] <- quote(browser())
|
||||
1797: [[
|
||||
^
|
||||
## 4
|
||||
|
||||
source("basicModel.R")
|
||||
Error in source("basicModel.R") : basicModel.R:95:1: unexpected symbol
|
||||
94:
|
||||
95: ixQ
|
||||
^
|
||||
|
||||
## 5.a
|
||||
> + Error in source(file = "/home/vitoshka/works/pbm/R/S4.R") (from #1) :
|
||||
/home/vitoshka/works/pbm/R/S4.R:36:62: unexpected ')'
|
||||
35: }, list(vname = as.name(".pix_v")),
|
||||
36: pname = as.name(".pix_p"))))
|
||||
^
|
||||
|
||||
## 5.b
|
||||
> + Error in source(file = "/home/vitoshka/works/pbm/R/S4.R") (from #1) :
|
||||
c:/home/vitoshka/works/pbm/R/S4.R:36:62: unexpected ')'
|
||||
35: }, list(vname = as.name(".pix_v")),
|
||||
36: pname = as.name(".pix_p"))))
|
||||
^
|
||||
>
|
||||
|
||||
|
||||
## 6 first line is not a pattern!
|
||||
+ . + Error in base::source(file = file, echo = echo, local = local, print.eval = print.eval, (from #95) :
|
||||
/tmp/model_mixture.R@4:5:13: unexpected symbol
|
||||
4: Mq$DATA$ixs$clust <- data$ixQ
|
||||
5: Mq
|
||||
|
||||
|
||||
## 7 don't highlight dates
|
||||
id lat lon obs_date
|
||||
Min. : 1.00 Min. :21.57 Min. :-179.88 01/02/1997 04:16:53: 1
|
||||
1st Qu.: 99.25 1st Qu.:24.36 1st Qu.:-147.38 01/02/1997 05:56:25: 1
|
||||
Median :197.50 Median :25.64 Median :-119.64 01/04/1997 17:41:54: 1
|
||||
Mean :197.50 Mean :27.21 Mean : -21.52 01/05/1997 17:20:07: 1
|
||||
3rd Qu.:295.75 3rd Qu.:27.41 3rd Qu.: 153.66 01/06/1997 04:31:13: 1
|
||||
Max. :394.00 Max. :39.84 Max. : 179.93 01/06/1997 06:12:56: 1
|
||||
(Other) :388
|
31
.emacs.d/elpa/ess-20160208.453/etc/Rnw-ess-bugs.Rnw
Normal file
31
.emacs.d/elpa/ess-20160208.453/etc/Rnw-ess-bugs.Rnw
Normal file
@@ -0,0 +1,31 @@
|
||||
|
||||
|
||||
|
||||
<<coxph>>=
|
||||
|
||||
## reported by Terry Therneau
|
||||
coxph <- function(formula, data, weights, subset, na.action,
|
||||
init, control, ties= c("efron", "breslow", "exact"),
|
||||
singular.ok =TRUE, robust=FALSE,
|
||||
model=FALSE, x=FALSE, y=TRUE, tt, method=ties, ...) {
|
||||
|
||||
ties <- match.arg(ties)
|
||||
Call <- match.call()
|
||||
|
||||
... (20 lines omitted)
|
||||
|
||||
timetrans <- attr(Terms, "specials")$tt
|
||||
if (length(timetrans)) {
|
||||
<<coxph-transform>>
|
||||
}
|
||||
|
||||
## next lines should not be ofsetted
|
||||
<<coxph-setup>>
|
||||
<<coxph-penal>>
|
||||
<<coxph-compute>>
|
||||
<<coxph-finish>>
|
||||
}
|
||||
@
|
||||
|
||||
|
||||
|
31
.emacs.d/elpa/ess-20160208.453/etc/SAS-bugs.sas
Normal file
31
.emacs.d/elpa/ess-20160208.453/etc/SAS-bugs.sas
Normal file
@@ -0,0 +1,31 @@
|
||||
|
||||
/********************/
|
||||
/* comment box*/
|
||||
/********************/
|
||||
|
||||
ods listing;
|
||||
|
||||
|
||||
/* From: Star Ying <starying@outlook.com> */
|
||||
/* Subject: [ESS] Another indentation error */
|
||||
/* To: "ess-help@r-project.org" <ess-help@r-project.org> */
|
||||
/* Date: Tue, 26 Mar 2013 14:33:22 -0400 (5 minutes, 16 seconds ago) */
|
||||
/* X-Boundary: ________________________________________________________________________________________________________________________________________________________________________________________________________ */
|
||||
|
||||
/* So I have another indentation error with ess and emacs that I have run into. For the example below: */
|
||||
|
||||
data example;
|
||||
merge
|
||||
lib.data lib.data2
|
||||
|
||||
%if val=ue %then %do;
|
||||
lib.data3
|
||||
%end;
|
||||
;
|
||||
by var;
|
||||
|
||||
/* The last line produces an error if I hit tab or if I try to indent that */
|
||||
/* region. Emacs produces the error */
|
||||
/* "invalid search bound (wrong side of point)". The code itself is valid and runs */
|
||||
/* in sas proper. Is this just me or is this a reproducible error? */
|
||||
|
200
.emacs.d/elpa/ess-20160208.453/etc/TODO.org
Normal file
200
.emacs.d/elpa/ess-20160208.453/etc/TODO.org
Normal file
@@ -0,0 +1,200 @@
|
||||
* COMPLETION
|
||||
** DONE make eldoc automatically pick available sub-process :13_09:
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "DONE" [2013-06-26 Wed 16:51]
|
||||
:END:
|
||||
** TODO make eldoc (actually ess--fun.start) work from withing strings
|
||||
* TRACEBUG
|
||||
** DONE put back ess-debug-goto-input-event-marker
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-06-21 Fri 01:18]
|
||||
:END:
|
||||
[2013-06-18 Tue] [[gnus:nnfolder%2Barchive:sent-2013-June#87sj0fulny.fsf@gmail.com][Email to Marius Hofert: Re: {ESS} A suggestion for deb]]
|
||||
** TODO make ess-selection-mode-map or just use ess-debug-mode-map
|
||||
When recover mode is on, it would be very convenient to exit it with M-Q.
|
||||
[2013-06-12 Wed]
|
||||
** DONE tracebug detects only english error messages.
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-06-21 Fri 01:18]
|
||||
:END:
|
||||
Try to solve with gettext R's functionality. Partially solved (for most
|
||||
important cases) by relaxing regular expressions.
|
||||
|
||||
** DONE C-c C-c with ess-inject-source=t deletes files faster than R can process
|
||||
- State "DONE" from "TODO" [2013-06-26 Wed 16:46]
|
||||
|
||||
** DONE tramp references not found
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-08-12 ma 23:40]
|
||||
:END:
|
||||
[2013-07-08 ma] [[file:~/works/pbm/R/hierarchy.R::..st_is_old..%20<-][file:~/works/pbm/R/hierarchy.R::..st_is_old.. <-]]
|
||||
|
||||
** DONE watch window behaves unexpectedly
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2014-03-31 Mon 20:13]
|
||||
:END:
|
||||
[2013-06-27 Thu]
|
||||
* DEVELOPER
|
||||
** DONE [#A] Eval in developer is broken
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-06-26 Wed 16:51]
|
||||
:END:
|
||||
** TODO "initialize" method is not injected
|
||||
|
||||
** DONE don't ask on C-t l for package if already in a package and dev is active
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-08-12 ma 23:42]
|
||||
:END:
|
||||
It interrupts the workflow unnecessarily and feels differently from C-c C-l
|
||||
[2013-07-10 wo]
|
||||
|
||||
* SAS
|
||||
** DONE remote M-x ess-sas-interactive via shell with ssh
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-08-12 ma 23:38]
|
||||
:END:
|
||||
sets ess-process-name-list to (("shell")) This prevents iESS[SAS] evaluation
|
||||
since a value of (("SAS")) would be necessary for that.
|
||||
|
||||
* INDENTATION
|
||||
** TODO closing ) match the function keyword
|
||||
foo(a,
|
||||
b
|
||||
)
|
||||
|
||||
instead of current:
|
||||
|
||||
foo(a,
|
||||
b
|
||||
)
|
||||
|
||||
And
|
||||
|
||||
foo(
|
||||
a,
|
||||
b
|
||||
)
|
||||
|
||||
instead of
|
||||
|
||||
foo(
|
||||
a,
|
||||
b
|
||||
)
|
||||
|
||||
* EVALUATION
|
||||
** TODO implement block-based evaluation
|
||||
|
||||
>>>>> Peter Meilstrup on Fri, 10 Jan 2014 23:25:01 -0800 wrote:
|
||||
>>
|
||||
>>> Over both eval-function (which doesn't usually do what I want when I
|
||||
>>> have inner functions) and eval-paragraph (which doesn't when I put a
|
||||
>>> line break in a function definition), I would prefer a command that
|
||||
>>> did "evaluate all lines that include the top-level bracket enclosing
|
||||
>>> point." That would be easy to implement using parse-partial-sexp and
|
||||
>>> cover the case discussed here.
|
||||
|
||||
>> I would be happy to implement this. Then we would be able to inject the
|
||||
>> source code reliably.
|
||||
>>
|
||||
>> A bit of an issue is the paragraph evaluation. A common pattern in R
|
||||
>> interactive code is to have a bunch of one-liners to be evaluated at
|
||||
>> once. Top-level-form evaluation will break this pattern unless we expand
|
||||
>> the evaluated region to the whole paragraph containing the form.
|
||||
>>
|
||||
>> Sometimes I need to evaluate an inner form as well. A natural thing
|
||||
>> would be to put it on C-u, but C-u is historically taken for a not very
|
||||
>> useful visual evaluation toggling.
|
||||
>>
|
||||
>> Any ideas/proposals are welcome.
|
||||
>>
|
||||
>> Vitalie
|
||||
>>
|
||||
|
||||
|
||||
* MISC
|
||||
** TODO [#A] populate ess-autoload.el and call it from ess-site.el :13_09:
|
||||
This will ensure that very quick start both for (require "ess-start") and
|
||||
MELPA users.
|
||||
** TODO [#B] build ert based unit test suit :13_09:
|
||||
** TODO split ess-mode into specialized derived modes
|
||||
** DONE set PAGER="cat" environment variable for tramp process if unset?
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2014-03-31 Mon 20:13]
|
||||
:END:
|
||||
** TODO cleanup ESS namespace
|
||||
[2013-06-27 Thu]
|
||||
** DONE remove reference to ssh.el from manual + add tramp workflow
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-10-16 Wed 19:17]
|
||||
:END:
|
||||
[2013-07-10 wo] [[gnus:nnimap%2BSpinuVit:INBOX#51DD58EF.1010702@yahoo.de][Email from Jannis: Re: {ESS} ess-eldoc via ssh re]]
|
||||
** TODO check Rodney's report on bastard symlinks
|
||||
[2013-07-11 do]
|
||||
** DONE check if ess-remote works
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-10-16 Wed 19:17]
|
||||
:END:
|
||||
[2013-08-12 ma]
|
||||
|
||||
** CANCELLED Help focus does not honor focus-follows-mouse/mouse-autoselect-window :CANCELLED:
|
||||
:LOGBOOK:
|
||||
- State "CANCELLED" from "TODO" [2013-10-16 Wed 19:16] \\
|
||||
was not a bug: said users may want to consider setting ess-help-pop-to-buffer to nil
|
||||
:END:
|
||||
If you have focus-follows-mouse and mouse-autoselect-window set to t,
|
||||
then ask for help in an *R* buffer, i.e.
|
||||
> ?setwd
|
||||
|
||||
The help buffer steals focus permanently instead of surrendering it
|
||||
to mouse movement; you need to physically click in the *R*
|
||||
buffer to restore the focus following the mouse. C-c C-d C-d
|
||||
behaves similarly. Ideally, we should respect the user's settings
|
||||
of focus-follows-mouse/mouse-autoselect-window in this common
|
||||
help/*R* buffer arrangement.
|
||||
** TODO Make an option to remember eval-and-go code in comint history
|
||||
** DONE DESCRIPTION file is killed if set to R-mode
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2013-10-16 Wed 18:15]
|
||||
:END:
|
||||
** TODO eldoc should ignore some functions
|
||||
Some functions have no useful argument information to report and they
|
||||
should simply be ignored. Ideally, this feature would be customizable
|
||||
so that each user could add their unfavorite functions. To start, I
|
||||
would put suggest: (), c(), list(), sqrt(), t()
|
||||
** TODO ess-doc-map, ess-extra-map, and ess-dev-map are present "everywhere"
|
||||
notably in ess-help, inferior-ess, and ess-mode. It would be *really*
|
||||
user friendly if we have a "submenu" for each of these maps, and them
|
||||
in both ESS and iESS (or all 4: ESS, iESS, ESS-help, ESS-transcript, ..).
|
||||
** DONE ess-execute-screen-options wrong in terminal
|
||||
:LOGBOOK:
|
||||
- State "DONE" [2014-03-31 Mon 20:11]
|
||||
:END:
|
||||
[2013-12-19 Thu] [[gnus:nnimap%2BSpinuVit:ESS#CAD%3D7RJZ4EHETKF4LPJpzuw0uO9AuzOtWDYVnV1cZAVQxAotVxg@mail.gmail.com][Email from Ali Tofigh: {ESS} ess-execute-screen-optio]]
|
||||
** TODO Implement "Extract Function" functionality
|
||||
Proposed by Andreas Leha:
|
||||
,----
|
||||
| RStudio can analyze a selection of code from within the source editor
|
||||
| and automatically convert it into a re-usable function. Any "free"
|
||||
| variables within the selection (objects that are referenced but not
|
||||
| created within the selection) are converted into function arguments
|
||||
`----
|
||||
** DONE > a + b + c is not cleaned correctly with C-u C-u C-y
|
||||
:LOGBOOK:
|
||||
- State "DONE" from "TODO" [2014-03-31 Mon 20:05]
|
||||
:END:
|
||||
While you are in this part of the code, can you add C-u C-u C-y to the ESS
|
||||
menu item, although maybe it belongs on the Edit menu. Not clear to me
|
||||
which would be better.
|
||||
|
||||
Thanks
|
||||
Rich
|
||||
[2014-02-20 Thu] [[gnus:nnimap%2BSpinuVit:ESS/ESS-core#CAGx1TMCSfK3XK6YghxomP03R_tFD2AiC4X%3D0NDcvoje%3D%2B9vMWw@mail.gmail.com][Email from Richard M. Heiberger: bug in ess-transcript-clean-re]]
|
||||
|
||||
* RStudio (excerpts from Hadley's R-packages book)
|
||||
** TODO Build & reload
|
||||
Available in RStudio via Cmd + Shift + B. This in- stalls the package,
|
||||
restarts R, and then reloads the package with library() (doing this by hand
|
||||
is painful).
|
||||
** TODO Jump to github file view. If lines are selected jump to those lines.
|
||||
This is probably there in projectile.
|
27
.emacs.d/elpa/ess-20160208.453/etc/backbug5
Normal file
27
.emacs.d/elpa/ess-20160208.453/etc/backbug5
Normal file
@@ -0,0 +1,27 @@
|
||||
#!/bin/sh
|
||||
# ESS[BUGS]: 02/18/2004
|
||||
# runs BUGS taking commands from command file
|
||||
#
|
||||
|
||||
case `config.guess` in
|
||||
alpha*-dec-*) BUGS=bugs05.decalpha;;
|
||||
hppa*-hp-hpux*) BUGS=bugs05.hp;;
|
||||
i?86-pc-cygwin) BUGS=bugs05.exe;;
|
||||
i?86-*-freebsd*) BUGS=bugs05.freebsd;;
|
||||
powerpc*-*-*) BUGS=bugs05.rs6000;;
|
||||
sparc-sun-solaris*) BUGS=bugs05.sparc;;
|
||||
mips-sgi-irix*) BUGS=bugs05.sgi;;
|
||||
mips-dec-*) BUGS=bugs05.decmips;;
|
||||
esac
|
||||
|
||||
case $# in
|
||||
1) test -f bugs.bog && rm -f bugs.bog || true
|
||||
$BUGS bugs.buf bugs.bog bugs.out bugs.ind bugs1.out bugs1.ind $1
|
||||
chmod -w bugs.bog
|
||||
;;
|
||||
2) test -f $1.bog && rm -f $1.bog || true
|
||||
$BUGS $1.buf $1.bog $1.out $1.ind ${1}1.out ${1}1.ind $2
|
||||
chmod -w $1.bog
|
||||
;;
|
||||
*) echo "usage: $0 [default_output_name] command_file";;
|
||||
esac
|
20
.emacs.d/elpa/ess-20160208.453/etc/backbug5.sparc
Normal file
20
.emacs.d/elpa/ess-20160208.453/etc/backbug5.sparc
Normal file
@@ -0,0 +1,20 @@
|
||||
#!/bin/sh
|
||||
# ESS[BUGS]: 02/17/2004
|
||||
# runs BUGS taking commands from command file
|
||||
#
|
||||
|
||||
case $# in
|
||||
1) bugs05.sparc 32 bugs $1
|
||||
cp -fp bugs.log bugs.bog
|
||||
chmod -w bugs.bog
|
||||
;;
|
||||
2) bugs05.sparc 32 $1 $2
|
||||
cp -fp $1.log $1.bog
|
||||
chmod -w $1.bog
|
||||
;;
|
||||
3) bugs05.sparc $1 $2 $3
|
||||
cp -fp $2.log $2.bog
|
||||
chmod -w $2.bog
|
||||
;;
|
||||
*) echo "usage: $0 [[number_of_bins] default_output_name] command_file";;
|
||||
esac
|
27
.emacs.d/elpa/ess-20160208.453/etc/backbugs
Executable file
27
.emacs.d/elpa/ess-20160208.453/etc/backbugs
Executable file
@@ -0,0 +1,27 @@
|
||||
#!/bin/sh
|
||||
# ESS[BUGS]: 02/18/2004
|
||||
# runs BUGS taking commands from command file
|
||||
#
|
||||
|
||||
case `config.guess` in
|
||||
i?86-pc-cygwin) BUGS=bugs0603.exe;;
|
||||
i?86-*-linux*) BUGS=bugs0600.linux;;
|
||||
sparc-sun-solaris*) BUGS=bugs603.sparc;;
|
||||
mips-sgi-irix*) BUGS=bugs06.sgi;;
|
||||
esac
|
||||
|
||||
case $# in
|
||||
1) $BUGS 32 bugs $1 2>> bugs.log
|
||||
cp -fp bugs.log bugs.bog
|
||||
chmod -w bugs.bog
|
||||
;;
|
||||
2) $BUGS 32 $1 $2 2>> $1.log
|
||||
cp -fp $1.log $1.bog
|
||||
chmod -w $1.bog
|
||||
;;
|
||||
3) $BUGS $1 $2 $3 2>> $2.log
|
||||
cp -fp $2.log $2.bog
|
||||
chmod -w $2.bog
|
||||
;;
|
||||
*) echo "usage: $0 [[number_of_bins] default_output_name] command_file";;
|
||||
esac
|
20
.emacs.d/elpa/ess-20160208.453/etc/backbugs.sparc
Normal file
20
.emacs.d/elpa/ess-20160208.453/etc/backbugs.sparc
Normal file
@@ -0,0 +1,20 @@
|
||||
#!/bin/sh
|
||||
# ESS[BUGS]: 02/17/2004
|
||||
# runs BUGS taking commands from command file
|
||||
#
|
||||
|
||||
case $# in
|
||||
1) bugs603.sparc 32 bugs $1
|
||||
cp -fp bugs.log bugs.bog
|
||||
chmod -w bugs.bog
|
||||
;;
|
||||
2) bugs603.sparc 32 $1 $2
|
||||
cp -fp $1.log $1.bog
|
||||
chmod -w $1.bog
|
||||
;;
|
||||
3) bugs603.sparc $1 $2 $3
|
||||
cp -fp $2.log $2.bog
|
||||
chmod -w $2.bog
|
||||
;;
|
||||
*) echo "usage: $0 [[number_of_bins] default_output_name] command_file";;
|
||||
esac
|
67
.emacs.d/elpa/ess-20160208.453/etc/checkTriple.Rd
Normal file
67
.emacs.d/elpa/ess-20160208.453/etc/checkTriple.Rd
Normal file
@@ -0,0 +1,67 @@
|
||||
\name{checkTriple}
|
||||
\title{Check Consistency of Conditional Independence for a Triple of Nodes}
|
||||
\usage{
|
||||
"An Rd file exposing an ESS bug in (ess-next-code-line) :
|
||||
Jump to '\examples{' and the first code line (= all '##...') and
|
||||
use C-c C-n to send it to R. It works, *but* point does not advance to
|
||||
the next line; but rather jumps backward to the 50'percent' line.
|
||||
Adding a percent 'o/o' sign here ``fixes'' this bug (so I don't do it) "
|
||||
|
||||
checkTriple(version.unf = c(NA, NA),
|
||||
maj.rule = FALSE, verbose = FALSE)
|
||||
}
|
||||
\arguments{
|
||||
\item{version.unf}{
|
||||
(integer) vector of length two: .............}
|
||||
\item{maj.rule}{logical indicating that the following majority rule
|
||||
is applied: if \code{b} is in less than
|
||||
50\% of the checked sepsets, we say that \code{b} is in \bold{no} sepset. If
|
||||
\code{b} is in more than 50\% of the checked sepsets, we say that
|
||||
\code{b} is in \bold{all} sepsets. If \code{b} is in exactly 50\% of the
|
||||
checked sepsets, the triple is considered \sQuote{ambiguous}.}
|
||||
\item{verbose}{Logical asking for detailed output of intermediate steps.}
|
||||
}
|
||||
\description{
|
||||
For each subset .........
|
||||
}
|
||||
\references{
|
||||
D. Colombo and M.H. Maathuis (2013).
|
||||
Order-independent constraint-based causal structure learning,
|
||||
(arXiv:1211.3295v2).
|
||||
}
|
||||
|
||||
\examples{
|
||||
##################################################
|
||||
## Using Gaussian Data
|
||||
##################################################
|
||||
## Load predefined data
|
||||
data(gmG)
|
||||
n <- nrow(gmG8$x)
|
||||
p <- ncol(gmG8$x)
|
||||
|
||||
## define independence test (partial correlations), and test level
|
||||
indepTest <- gaussCItest
|
||||
alpha <- 0.01
|
||||
## define sufficient statistics
|
||||
suffStat <- list(C = cor(gmG8$x), n = n)
|
||||
|
||||
## estimate CPDAG
|
||||
pc.fit <- pc(suffStat, indepTest, p=p, alpha=alpha, verbose = TRUE)
|
||||
|
||||
if (require(Rgraphviz)) {
|
||||
## show estimated CPDAG
|
||||
par(mfrow=c(1,2))
|
||||
plot(pc.fit, main = "Estimated CPDAG")
|
||||
plot(gmG8$g, main = "True DAG")
|
||||
}
|
||||
|
||||
checkTriple(a = 6, b = 1, c = 8,
|
||||
nbrsA = c(1,5,7),
|
||||
nbrsC = c(1,5),
|
||||
sepsetA = pc.fit@sepset[[a]][[c]],
|
||||
sepsetC = pc.fit@sepset[[c]][[a]],
|
||||
suffStat=suffStat, indepTest=indepTest, alpha=alpha,
|
||||
version.unf = c(2,2),
|
||||
verbose = TRUE)
|
||||
}
|
||||
\keyword{manip}
|
20
.emacs.d/elpa/ess-20160208.453/etc/chol2inv-ex.Rd
Normal file
20
.emacs.d/elpa/ess-20160208.453/etc/chol2inv-ex.Rd
Normal file
@@ -0,0 +1,20 @@
|
||||
\title{chol2inv}
|
||||
\name{chol2inv-methods}
|
||||
\description{
|
||||
Invert a symmetric, positive definite square matrix from its Choleski
|
||||
decomposition. Equivalently, compute \eqn{(X'X)^{-1}}{(X'X)^(-1)}
|
||||
from the (\eqn{R} part) of the QR decomposition of \eqn{X}.
|
||||
}
|
||||
\seealso{
|
||||
\code{\link[base]{chol2inv}} (from the \pkg{base} package),
|
||||
\code{\link{solve}}.
|
||||
}
|
||||
%%-- In Rd preview (after C-c C-p), "se" ([s]kip to [e]xamples):
|
||||
%%-- "l" works at the 1st line, but does not go further from the 2nd
|
||||
\examples{
|
||||
(M <- cbind(1, 1:3, c(1,3,7)))
|
||||
(cM <- chol(M)) # a "Cholesky" object...
|
||||
chol2inv(cM) \%*\% M # the identity
|
||||
stopifnot(all(chol2inv(cM) \%*\% M - Diagonal(nrow(M))) < 1e-10)
|
||||
}
|
||||
\keyword{algebra}
|
30
.emacs.d/elpa/ess-20160208.453/etc/completion_ideas.R
Normal file
30
.emacs.d/elpa/ess-20160208.453/etc/completion_ideas.R
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
## inspired by:
|
||||
## https://github.com/rstudio/rstudio/pull/191
|
||||
|
||||
## nested calls should work
|
||||
df[a][, |]
|
||||
|
||||
## matrix, list, environments
|
||||
l <- list(aaaa = 1111, bbbb = 2222)
|
||||
l[a|] ## -> "aaaa" (quoted!)
|
||||
|
||||
## data table
|
||||
dt <- data.table(aaaa = 1111, bbbb = 22222)
|
||||
dt[, a|] # -> aaaa (unquoted!)
|
||||
|
||||
## attributes
|
||||
x <- ""
|
||||
attr(x, "foo") <- function(alpha, beta) {}
|
||||
attr(x, "foo")(al| # -> "alpha"
|
||||
|
||||
## chains
|
||||
mtcars %>% dplyr::select(mp| #-> mpg (unquoted))
|
||||
|
||||
## models
|
||||
lm(mpg ~ cy| , data = mtcars) #-> cyl
|
||||
|
||||
## "by" keyword in data.table, inner_join, etc
|
||||
inner_join(foo, bar, by = c(| # provides completions for variables in foo when
|
||||
# on the left side of an =, and bar when on the
|
||||
# right side of an =.
|
1560
.emacs.d/elpa/ess-20160208.453/etc/config.guess
vendored
Executable file
1560
.emacs.d/elpa/ess-20160208.453/etc/config.guess
vendored
Executable file
File diff suppressed because it is too large
Load Diff
114
.emacs.d/elpa/ess-20160208.453/etc/ess-julia.jl
Normal file
114
.emacs.d/elpa/ess-20160208.453/etc/ess-julia.jl
Normal file
@@ -0,0 +1,114 @@
|
||||
module ESS
|
||||
|
||||
|
||||
function all_help_topics()
|
||||
Base.Help.init_help()
|
||||
## show all categories
|
||||
for (func, _ ) in Base.Help.MODULE_DICT
|
||||
if !isempty(Base.Help.MODULE_DICT[func])
|
||||
println()
|
||||
show(func);
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function help(topic::AbstractString)
|
||||
VERSION >= v"0.4-" ?
|
||||
eval(current_module(), parse("@doc $topic")) :
|
||||
Base.Help.help(topic)
|
||||
end
|
||||
|
||||
## modified version of function show(io::IO, m::Method)
|
||||
function fun_args(m::Method)
|
||||
tv, decls, file, line = Base.arg_decl_parts(m)
|
||||
io = STDOUT::IO
|
||||
if !isempty(tv)
|
||||
Base.show_delim_array(io, tv, '{', ',', '}', false)
|
||||
end
|
||||
li = m.func.code
|
||||
e = Base.uncompressed_ast(li)
|
||||
argnames = e.args[1]
|
||||
print(io, "(")
|
||||
print_joined(io, [escape_string(isempty(d[2]) ? d[1] : d[1]*"::"*d[2]) for d in decls], ",", ",")
|
||||
print(io, ")")
|
||||
end
|
||||
|
||||
VERSION >= v"0.4-" && (Base.function_module(f::Function)=f.env.module)
|
||||
|
||||
## modified versionof show(io::IO, mt::MethodTable)
|
||||
function fun_args(f::Function)
|
||||
mt = f.env
|
||||
mod = Base.function_module(f)
|
||||
if mod == Main
|
||||
mod = "nil"
|
||||
end
|
||||
print("(list \"$mod\" nil '(")
|
||||
d = mt.defs
|
||||
while d != nothing && d != ()
|
||||
print("\"")
|
||||
## method
|
||||
fun_args(d)
|
||||
print("\" ")
|
||||
d = d.next
|
||||
end
|
||||
print("))")
|
||||
end
|
||||
|
||||
function fun_args(s::ASCIIString)
|
||||
try
|
||||
m = eval(current_module(), parse(s))
|
||||
if typeof(m) != ASCIIString
|
||||
fun_args(m)
|
||||
end
|
||||
catch
|
||||
print("(list nil nil nil)")
|
||||
end
|
||||
end
|
||||
|
||||
function fun_args(t::DataType)
|
||||
print("(list nil nil '(")
|
||||
for d = fieldnames(t)
|
||||
print("\"$d\" ")
|
||||
end
|
||||
print("))")
|
||||
end
|
||||
|
||||
|
||||
### OBJECT COMPLETION
|
||||
function components(m::Module)
|
||||
for v in sort(names(m))
|
||||
s = string(v)
|
||||
if isdefined(m,v)
|
||||
println(rpad(s, 30), summary(eval(m,v)))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function components(t::DataType)
|
||||
for v in sort(fieldnames(t))
|
||||
println(rpad(string(v), 30), "field")
|
||||
end
|
||||
end
|
||||
|
||||
function components(v)
|
||||
t = typeof(v)
|
||||
if isa(t, DataType)
|
||||
return components(t)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
### MISC
|
||||
function main_modules()
|
||||
mainmod = current_module()
|
||||
for nm in names(mainmod)
|
||||
if isdefined(mainmod, nm)
|
||||
mod = eval(mainmod, nm)
|
||||
if isa(mod, Module)
|
||||
print("\"$nm\" ")
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
221
.emacs.d/elpa/ess-20160208.453/etc/ess-roxy-tests.R
Normal file
221
.emacs.d/elpa/ess-20160208.453/etc/ess-roxy-tests.R
Normal file
@@ -0,0 +1,221 @@
|
||||
##' \code{loadings(object)} and then design your own plotting method.
|
||||
##' @title Side by side scores and loadings plot
|
||||
##' @usage slplot(object, pcs=c(1,2), scoresLoadings=c(TRUE, TRUE),
|
||||
##' sl="def", ll="def", hotelling=0.95, rug=TRUE, sub=NULL,...)
|
||||
##' @param object
|
||||
##' @param pcs
|
||||
##' @param tjo
|
||||
##' @return None, used for side effect.
|
||||
##' @export
|
||||
##' @author Henning Redestig
|
||||
setMethod("slplot", "pcaRes",
|
||||
function(object, pcs=c(1,2), tjo) {
|
||||
#(ess-roxy-get-function-args)
|
||||
opar <- par(no.readonly=TRUE)
|
||||
cl <- match.call()
|
||||
})
|
||||
|
||||
##' .. content for \description{} (no empty lines) ..
|
||||
##'
|
||||
##' .. content for \details{} ..
|
||||
##' @title
|
||||
##' @param a
|
||||
##' @param b
|
||||
##' @param d
|
||||
##' @param asd
|
||||
##' @return
|
||||
##' @author Henning Redestig
|
||||
trickyInArgsComments <- function(a,#comment
|
||||
b,#hejhopp trams
|
||||
d,asd) {
|
||||
print("hello")
|
||||
}
|
||||
|
||||
##' .. content for \description{} (no empty lines) ..
|
||||
##'
|
||||
##' .. content for \details{} ..
|
||||
##' @title
|
||||
##' @param a
|
||||
##' @param b
|
||||
##' @param cc
|
||||
##' @return
|
||||
##' @author Henning Redestig
|
||||
withdef <- function(a, b=c("asd","ffd", "asd", "ffd",
|
||||
"asd",
|
||||
"ffd","asd",
|
||||
"ffd"), cc) {
|
||||
print("hello")
|
||||
|
||||
}
|
||||
|
||||
setClass(Class="inference", representation=representation(model="character"
|
||||
, sample.size="numeric"
|
||||
, robust.se="logical"
|
||||
, two.sided="logical"
|
||||
, ci.level="numeric"), contains=c("matrix"))
|
||||
|
||||
##' .. content for \description{} (no empty lines)
|
||||
##'
|
||||
##' .. content for \details{} ..
|
||||
##' @title asd
|
||||
##' @param a
|
||||
##' @param asdsd
|
||||
##' @param sd
|
||||
##' @param ...
|
||||
##' @return s
|
||||
##' @author Henning Redestig
|
||||
tempFixNasFunction <- function(a,asdsd, sd, ...) {
|
||||
asds
|
||||
}
|
||||
|
||||
setGeneric("updateMu", function(respM, gamma, ...)
|
||||
standardGeneric("updateMu"))
|
||||
|
||||
|
||||
## (make-local-variable 'adaptive-fill-regexp)
|
||||
## (setq adaptive-fill-regexp (concat ess-roxy-str adaptive-fill-regexp))
|
||||
## (make-local-variable 'adaptive-fill-first-line-regexp)
|
||||
## (setq adaptive-fill-first-line-regexp (concat ess-roxy-str adaptive-fill-first-line-regexp))
|
||||
## (make-local-variable 'paragraph-start)
|
||||
## (setq paragraph-start (concat "\\(" ess-roxy-str "\\)*" paragraph-start))
|
||||
## (make-local-variable 'paragraph-separate)
|
||||
## (setq paragraph-separate (concat "\\(" ess-roxy-str "\\)*" paragraph-separate))
|
||||
## (auto-fill-mode)
|
||||
asd
|
||||
|
||||
##' aqdasd lksa odnsl dlsakdn lsakdn sladn asijdi j 1. asdsd alksnd
|
||||
##' lasdn ldnad
|
||||
##'
|
||||
##'
|
||||
##' alkdnal dl lakd lasdnladna ld aldan lda dlakd nladn a amd lakdn
|
||||
##' ajdn asjdns
|
||||
##'
|
||||
##' lajnsd jasdn aksjdnaksjnd asjdnaksdnajsdnajsd aksdn askdjn
|
||||
##' akjdn aksdnkasjdnka
|
||||
##'
|
||||
##' 1. aldn adlnsald ladn saldnlaksd naskl
|
||||
##' 2. ad asdjnksadn adjn skajan kda dksadkas dkjan dkasndkadn
|
||||
##' ajsd nkj dakjd sd
|
||||
##' @title hej
|
||||
##' @param fitta asdadsd
|
||||
##' 1.
|
||||
##' 2. asd
|
||||
##' @param diagonals pung asa as a sad s dsa da das d asd asd add
|
||||
##' @param tjo asd
|
||||
##' @param asdasd
|
||||
##' @return me
|
||||
##' @author Henning Redestig
|
||||
tempFixNas <- function(fitta, diagonals, tjo, asdasd) {
|
||||
|
||||
for(i in index) {
|
||||
data <- otherdata[i]
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
##' Simply replace completely ajksbdkjsa djskbdkajbd
|
||||
##'
|
||||
##' ksdb skdb skasdaj ahd (ess-roxy-beg-of-field) (newline-and-indent)
|
||||
##' aksndlsakndlksdn jkahd ksn dkjands
|
||||
##' @title Temporary fix for missing values
|
||||
##' @param diagonals The diagonal to be replaced, i.e. the first,
|
||||
##' second and so on when looking at the fat version of the matrix
|
||||
##' @param tjo asdsdsdw
|
||||
##' @return The original matrix with completely missing rows/cols
|
||||
##' filled with zeroes. oasndsnd aksdnkasdnskans dkas ndkjasndksdn
|
||||
##' skandkand ksjandknsd
|
||||
##' @export
|
||||
##' @examples
|
||||
##' tempFixNas(iris)
|
||||
##' pi <- 1
|
||||
##' plot(x)
|
||||
##' @author Henning Redestig
|
||||
tempFixNas <- function(diagonals, tjo) {
|
||||
(ess-roxy-delete-args)
|
||||
wilcox.test
|
||||
(ess-roxy-goto-end-of-entry)
|
||||
badRows <- apply(mat, 1, function(x) all(is.na(x)))
|
||||
badCols <- apply(mat, 2, function(x) all(is.na(x)))
|
||||
mat[ badRows,] <- 0 (ess-roxy-get-args-list-from-def)
|
||||
mat[,badCols ] <- 0 (ess-roxy-get-args-list-from-entry)
|
||||
mat
|
||||
}
|
||||
|
||||
##' <description>
|
||||
##'
|
||||
##' <details>
|
||||
##' @title asdsd
|
||||
##' @param asd asd
|
||||
##' @param test1 asd
|
||||
##' @param asdsd
|
||||
##' @param tjo asdasd
|
||||
##' @return aa
|
||||
##' @author Henning Redestig
|
||||
tempFixNas <- function(asd,test1,asdsd,tjo=c("asd", "asdasd")) {
|
||||
## (ess-roxy-goto-end-of-entry)
|
||||
## (setq fun (ess-roxy-get-args-list-from-def))
|
||||
## (setq ent (ess-roxy-get-args-list-from-entry))
|
||||
## (ess-roxy-merge-args fun ent)
|
||||
## (ess-roxy-mrg-args fun ent)
|
||||
## (ess-roxy-get-args-list-from-entry)
|
||||
## (ess-roxy-get-function-args)
|
||||
## (ess-roxy-goto-end-of-entry)
|
||||
|
||||
## (setq here (ess-roxy-delete-args))
|
||||
## (ess-roxy-insert-args (ess-roxy-get-args-list-from-def) here)
|
||||
badRows <- apply(mat, 1, function(x) all(is.na(x)))
|
||||
badCols <- apply(mat, 2, function(x) all(is.na(x)))
|
||||
mat[ badRows,] <- 0
|
||||
mat[,badCols ] <- 0
|
||||
mat
|
||||
}
|
||||
|
||||
##' <description>
|
||||
##'
|
||||
##' <details>
|
||||
##' @title my title
|
||||
##' @param test1
|
||||
##' @param tjo
|
||||
##' @param pung
|
||||
##' @param str
|
||||
##' @return value
|
||||
##' @author Henning Redestig
|
||||
tempFixNasBad <- function(test1,tjo=c("asd", "asdasd"), pung, str) {
|
||||
asdsd# (car (cdr (ess-end-of-function nil t)))
|
||||
}
|
||||
|
||||
##' Provides Bayesian PCA, Probabilistic PCA, Nipals PCA, Inverse
|
||||
##' Non-Linear PCA and the conventional SVD PCA. A cluster based
|
||||
##' method for missing value estimation is included for comparison.
|
||||
##' BPCA, PPCA and NipalsPCA may be used to perform PCA on incomplete
|
||||
##' data as well as for accurate missing value estimation. A set of
|
||||
##' methods for printing and plotting the results is also provided.
|
||||
##' All PCA methods make use of the same data structure (pcaRes) to
|
||||
##' provide a unique interface to the PCA results. Developed at the
|
||||
##' Max-Planck Institute for Molecular Plant Physiology, Golm,
|
||||
##' Germany, RIKEN Plant Science Center Yokohama, Japan, and CAS-MPG
|
||||
##' Partner Institute for Computational Biology (PICB) Shanghai,
|
||||
##' P.R. China
|
||||
##'
|
||||
##' @name pcaMethods
|
||||
##' @aliases pcaMethods
|
||||
##' @docType package
|
||||
##' @title pcaMethods
|
||||
##' @useDynLib pcaMethods
|
||||
##' @author Wolfram Stacklies, Henning Redestig
|
||||
NULL
|
||||
|
||||
|
||||
#' Title
|
||||
#'
|
||||
#' @param par Lorem ipsum dolor sit amet, consectetur adipiscing
|
||||
#' elit. Vivamus ligula purus, ultricies quis odio non, vulputate
|
||||
#' finibus risus. Donec eleifend quis dolor ut rhoncus.
|
||||
#' @param par2 Lorem ipsum dolor sit amet, consectetur adipiscing
|
||||
#' elit. Vivamus ligula purus, ultricies quis odio non.
|
||||
#' @examples
|
||||
#' # This long comment line can be paragraph-filled without squashing
|
||||
#' # the following lines of code into the comment
|
||||
#' fun(arg)
|
||||
#' print(object)
|
15
.emacs.d/elpa/ess-20160208.453/etc/ess-rutils-help-start.R
Normal file
15
.emacs.d/elpa/ess-20160208.453/etc/ess-rutils-help-start.R
Normal file
@@ -0,0 +1,15 @@
|
||||
## Hacked help.start() to use with ess-rutils.el
|
||||
.rutils.help.start <- function (update=FALSE, remote=NULL) {
|
||||
home <- if (is.null(remote)) {
|
||||
if (tools:::httpdPort == 0L)
|
||||
tools::startDynamicHelp()
|
||||
if (tools:::httpdPort > 0L) {
|
||||
if (update)
|
||||
make.packages.html()
|
||||
paste("http://127.0.0.1:", tools:::httpdPort, sep="")
|
||||
}
|
||||
else stop(".rutils.help.start() requires the HTTP server to be running",
|
||||
call.=FALSE)
|
||||
} else remote
|
||||
paste(home, "/doc/html/index.html", sep="")
|
||||
}
|
56
.emacs.d/elpa/ess-20160208.453/etc/ess-s4.S
Normal file
56
.emacs.d/elpa/ess-20160208.453/etc/ess-s4.S
Normal file
@@ -0,0 +1,56 @@
|
||||
#### This is a dump of the S library used by S-mode with Version 4 of S.
|
||||
#### (from John Chambers ??)
|
||||
|
||||
#### S-mode session functions.
|
||||
#### assign(..., where=0) makes them last only for the current session.
|
||||
|
||||
### Martin Maechler: see also ./ess-sp3.S
|
||||
### which uses assign(.., wh=0) which seems better
|
||||
|
||||
".SmodeDump" <- function(x, name)
|
||||
{
|
||||
## dump function for S-mode
|
||||
assign(".SmodeTmp", options(error = dump.calls), where = 0, i = T)
|
||||
on.exit( {
|
||||
options(.SmodeTmp)
|
||||
remove(".SmodeTmp", where = 0)
|
||||
} )
|
||||
dump(x, file = name)
|
||||
}
|
||||
".SmodeLoad" <- function(x)
|
||||
{
|
||||
## skeleton of a dump.calls interface, enough to keep s-mode
|
||||
## informed that an error took place.
|
||||
pseudo <- function()
|
||||
cat(get.message(), "Dumped\n", sep = "", file = "|stderr")
|
||||
## source function for S-mode
|
||||
assign(".SmodeTmp", options(error = pseudo), where = 0, i = T)
|
||||
on.exit( {
|
||||
options(.SmodeTmp)
|
||||
remove(".SmodeTmp", where = 0)
|
||||
} )
|
||||
invisible(source(x))
|
||||
}
|
||||
|
||||
".SmodeObs" <- function(where, pattern)
|
||||
{
|
||||
if(pattern == "") objects(where) else objects(where, pattern)
|
||||
}
|
||||
|
||||
".SmodePaths" <- function()
|
||||
{
|
||||
## the paths for the directories in the search list
|
||||
temp <- search()
|
||||
value <- character(length(temp))
|
||||
for(i in seq(along.with = temp)) {
|
||||
obj <- database.object(i)
|
||||
if(is.character(obj) && length(obj) == 1)
|
||||
value[[i]] <- obj
|
||||
}
|
||||
value
|
||||
}
|
||||
|
||||
"smode.lvsave" <-
|
||||
c(".Last.value",
|
||||
".SmodeDump", ".SmodeLoad", ".SmodeObs", ".SmodePaths",
|
||||
"smode.lvsave")
|
76
.emacs.d/elpa/ess-20160208.453/etc/ess-sas-sh-command
Executable file
76
.emacs.d/elpa/ess-20160208.453/etc/ess-sas-sh-command
Executable file
@@ -0,0 +1,76 @@
|
||||
#!/bin/sh
|
||||
|
||||
### (C) 1997, Richard M. Heiberger.
|
||||
### This file is part of ESS.
|
||||
|
||||
## This file is free software; you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation; either version 2, or (at your option)
|
||||
## any later version.
|
||||
|
||||
## This file is distributed in the hope that it will be useful,
|
||||
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
## GNU General Public License for more details.
|
||||
|
||||
## A copy of the GNU General Public License is available at
|
||||
## http://www.r-project.org/Licenses/
|
||||
|
||||
|
||||
# For executing SAS, and running it in the proper manner for ESS
|
||||
# (feeding output back into appropriate ESS buffers).
|
||||
|
||||
#echo $0 $@
|
||||
#sas </dev/tty 1>$1 2>$2 $3
|
||||
|
||||
set -x
|
||||
stdout=$1
|
||||
stderr=$2
|
||||
shift 2
|
||||
set +x
|
||||
echo sas \</dev/tty 1\>$stdout 2\>$stderr $@
|
||||
sas </dev/tty 1>$stdout 2>$stderr $@
|
||||
|
||||
## From the SAS online tech support:
|
||||
##
|
||||
## Redirecting the SAS Log and Output under UNIX.
|
||||
##
|
||||
## There are several ways of redirecting the SAS Log and Output under
|
||||
## UNIX.
|
||||
##
|
||||
## To redirect the SAS Log, follow one of these steps:
|
||||
##
|
||||
## 1.
|
||||
## In the source code, place the following line:
|
||||
##
|
||||
## proc printto log=stdout;
|
||||
##
|
||||
## to make a duplicate copy of the log in a file in addition
|
||||
## to redirecting it to stdout, use this command to invoke
|
||||
## SAS:
|
||||
##
|
||||
## sas -altlog doit.log doit.sas
|
||||
##
|
||||
## 2.Execute SAS in the background and use the UNIX 'tail' command
|
||||
## to copy lines to stdout as they are added to the log. Use the
|
||||
## command:
|
||||
##
|
||||
## sas doit.sas &; tail -f doit.log
|
||||
##
|
||||
## To redirect the SAS Log and Output under the Korn shell, use the
|
||||
## following command:
|
||||
##
|
||||
## sas -stdio < doit.sas > doit.lst 2> doit.log
|
||||
##
|
||||
## To redirect the SAS Log and Output under the C-Shell, use the
|
||||
## following command:
|
||||
##
|
||||
## (sas -stdio < doit.sas > doit.lst) >& doit.log
|
||||
|
||||
## From WWW.SAS.COM:
|
||||
## How can I make SAS in batch mode behave like interactive SAS,
|
||||
## continue running my SAS job, and not enter syntax check mode when
|
||||
## it encounters an error?
|
||||
##
|
||||
## You can specify the NOSYNTAXCHECK option when you invoke your SAS
|
||||
## program.
|
49
.emacs.d/elpa/ess-20160208.453/etc/ess-sp3.S
Normal file
49
.emacs.d/elpa/ess-20160208.453/etc/ess-sp3.S
Normal file
@@ -0,0 +1,49 @@
|
||||
#### S-mode session functions.
|
||||
#### assign(..., where=0) makes them last only for the current session.
|
||||
|
||||
#### Well, turns out we have two slightly different versions of the S code.
|
||||
#### This is the one that I think gets used with S-Plus; I'll send along
|
||||
#### the other version as well, but morally they should be equivalent, there
|
||||
#### are just a couple of changes I seem to have made for S4. /John
|
||||
|
||||
### Martin Maechler: see also ./ess-s4.S
|
||||
### which does *not* use assign (why?)
|
||||
assign(".SmodeObs",
|
||||
function(where, pattern) {
|
||||
if(pattern == "") objects(where)
|
||||
else objects(where, pattern)
|
||||
}, where=0)
|
||||
|
||||
assign(".SmodeLoad",
|
||||
function(x)
|
||||
## source function for S-mode
|
||||
{
|
||||
assign(".SmodeTmp", options(error=dump.calls), where=0, i=T)
|
||||
on.exit({options(.SmodeTmp); remove(".SmodeTmp",where=0)})
|
||||
source(x)
|
||||
},
|
||||
where = 0)
|
||||
|
||||
assign(".SmodeDump",
|
||||
function(x, name)
|
||||
## dump function for S-mode
|
||||
{
|
||||
assign(".SmodeTmp", options(error=dump.calls), where=0, i=T)
|
||||
on.exit({options(.SmodeTmp); remove(".SmodeTmp",where=0)})
|
||||
dump(x, file=name)
|
||||
},
|
||||
where = 0)
|
||||
assign(".SmodePaths",
|
||||
function()
|
||||
## the paths for the directories in the search list
|
||||
{
|
||||
temp <- search()
|
||||
value <- character(length(temp))
|
||||
for(i in seq(along.with = temp)) {
|
||||
obj <- database.object(i)
|
||||
if(is.character(obj) && length(obj) == 1)
|
||||
value[[i]] <- obj
|
||||
}
|
||||
value
|
||||
},
|
||||
where = 0)
|
8
.emacs.d/elpa/ess-20160208.453/etc/function-outline.S
Normal file
8
.emacs.d/elpa/ess-20160208.453/etc/function-outline.S
Normal file
@@ -0,0 +1,8 @@
|
||||
f <- function()
|
||||
{
|
||||
## Purpose:
|
||||
## ----------------------------------------------------------------------
|
||||
## Arguments:
|
||||
## ----------------------------------------------------------------------
|
||||
## Author: $A$, Date: $D$
|
||||
}
|
56
.emacs.d/elpa/ess-20160208.453/etc/gpl-check
Executable file
56
.emacs.d/elpa/ess-20160208.453/etc/gpl-check
Executable file
@@ -0,0 +1,56 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ $# -eq 0 -o "$1" = "-h" -o "$1" = "-help" -o "$1" = "--help" ]
|
||||
then
|
||||
echo "usage: gpl-check [-h|-help|--help|-2|-3|-u|-n] file1 [file2 ...]"
|
||||
echo " -h|-help|--help print this help"
|
||||
echo " -2 print file names found with GPLv2+"
|
||||
echo " -3 print file names found with GPLv3+"
|
||||
echo " -u print file names found with a GPL of unknown version"
|
||||
echo " -n print file names with no GPL found"
|
||||
echo " file1 [file2 ...] list of files to check"
|
||||
else
|
||||
GPLV2=0
|
||||
GPLV3=0
|
||||
GPLVUNK=0
|
||||
NOGPL=0
|
||||
|
||||
for i
|
||||
do
|
||||
case $i in
|
||||
-2) GPLV2=1;;
|
||||
-3) GPLV3=1;;
|
||||
-23) GPLV2=1;GPLV3=1;;
|
||||
-u) GPLVUNK=1;;
|
||||
-n) NOGPL=1;;
|
||||
-nu|-un) GPLVUNK=1;NOGPL=1;;
|
||||
*) if [ $GPLV2 -eq 0 -a $GPLV3 -eq 0 -a $GPLVUNK -eq 0 -a $NOGPL -eq 0 ]
|
||||
then
|
||||
GPLV2=1
|
||||
GPLV3=1
|
||||
GPLVUNK=1
|
||||
NOGPL=1
|
||||
fi
|
||||
if grep -l 'either version 2, or' $i > /dev/null
|
||||
then
|
||||
if [ $GPLV2 -eq 1 ]
|
||||
then echo "$i GPLv2+"
|
||||
fi
|
||||
elif grep -l 'either version 3' $i > /dev/null
|
||||
then
|
||||
if [ $GPLV3 -eq 1 ]
|
||||
then echo "$i GPLv3+"
|
||||
fi
|
||||
elif grep -l 'GNU General Public License' $i > /dev/null
|
||||
then
|
||||
if [ $GPLVUNK -eq 1 ]
|
||||
then echo "$i GPLv unknown"
|
||||
fi
|
||||
else
|
||||
if [ $NOGPL -eq 1 ]
|
||||
then echo "$i no GPL"
|
||||
fi
|
||||
fi;;
|
||||
esac
|
||||
done
|
||||
fi
|
31
.emacs.d/elpa/ess-20160208.453/etc/icons/README
Normal file
31
.emacs.d/elpa/ess-20160208.453/etc/icons/README
Normal file
@@ -0,0 +1,31 @@
|
||||
|
||||
Creating pixmaps:
|
||||
|
||||
* spluslogo.xpm was dontated by David Smith at Insightful.
|
||||
|
||||
* Other icons were created by SJE, using mostly `kiconedit' and
|
||||
hand-editing.
|
||||
|
||||
* Transparency
|
||||
Need to add backgrounToolBarColor for XEmacs to show okay.
|
||||
e.g. /usr/share/xemacs-21.4.12/etc/toolbar/folder-cap-up.xpm
|
||||
has header:
|
||||
"X c Gray75 s backgroundToolBarColor",
|
||||
whereas I have set "c None" to indicate the background pixel; this line
|
||||
seems to work for both toolbars:
|
||||
". c None s backgroundToolBarColor",
|
||||
|
||||
* splus_letters_small.xpm
|
||||
|
||||
2010-05-18 & -21: SJE made this new Splus icon from the
|
||||
splus_letters_large.xpm (then image001.png from Louis Bajuk-Yorgan
|
||||
@tibco.com) file that Rich provided. I had to move the
|
||||
cross over to the left by one pixel, to then allow the image to be
|
||||
cropped to 48x48 (cropping performed in gimp). kiconedit was then
|
||||
used to rescale the icon to 24x24. Finally, background transparency
|
||||
added manually to the file, as noted above.
|
||||
|
||||
2010-05-21: updated file based on new image from TIBCO. Original
|
||||
51x38 cropped to 50x38 in xv, then shrunk to 25x19 in kiconedit.
|
||||
Transparency added, and removed a lot of the extra white pixels into
|
||||
background colours manually in kiconedit.
|
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rbuffer.xpm
Normal file
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rbuffer.xpm
Normal file
@@ -0,0 +1,30 @@
|
||||
/* XPM */
|
||||
static char *rbuffer[]={
|
||||
"24 24 3 1",
|
||||
". c None s backgroundToolBarColor",
|
||||
"a c #000000",
|
||||
"# c #1532ed",
|
||||
"........................",
|
||||
"...............#........",
|
||||
"...............##.......",
|
||||
".....#############......",
|
||||
".....##############.....",
|
||||
".....#############......",
|
||||
"...............##.......",
|
||||
"...............#........",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa..."};
|
45
.emacs.d/elpa/ess-20160208.453/etc/icons/rfunction.xpm
Normal file
45
.emacs.d/elpa/ess-20160208.453/etc/icons/rfunction.xpm
Normal file
@@ -0,0 +1,45 @@
|
||||
/* XPM */
|
||||
static char *rfunction[]={
|
||||
"24 24 18 1",
|
||||
"B c #000000",
|
||||
"k c #181818",
|
||||
"Q c #1f1f1f",
|
||||
"z c #232323",
|
||||
"L c #313131",
|
||||
"Z c #3c3c3c",
|
||||
"O c #404040",
|
||||
"a c #5e5e5e",
|
||||
"W c #676767",
|
||||
"U c #757575",
|
||||
"N c #848484",
|
||||
"P c #969696",
|
||||
"0 c #a0a0a0",
|
||||
". c None s backgroundToolBarColor",
|
||||
"G c #b9b9b9",
|
||||
"I c #c6c6c6",
|
||||
"T c #d5d5d5",
|
||||
"# c #1532ed",
|
||||
"........................",
|
||||
"...............#........",
|
||||
"...............##.......",
|
||||
".....#############......",
|
||||
".....##############.....",
|
||||
".....#############......",
|
||||
"...............##.......",
|
||||
"...............#........",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"..............az..zU....",
|
||||
"....ILBBz...GkP....aO...",
|
||||
"....zU......BG......LP..",
|
||||
"....BG.....UO.......0z..",
|
||||
"..BBBBBBP..zP.......GB..",
|
||||
"....BG.....BG........BI.",
|
||||
"....BG.....BG........BI.",
|
||||
"....BG.....LP.......GB..",
|
||||
"....BG.....NO.......PL..",
|
||||
"....BG......Q0......z0..",
|
||||
"....BG......TQU0..0ZW...",
|
||||
"..............NL..Z0....",
|
||||
"........................"};
|
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rline.xpm
Normal file
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rline.xpm
Normal file
@@ -0,0 +1,30 @@
|
||||
/* XPM */
|
||||
static char *rline[]={
|
||||
"24 24 3 1",
|
||||
". c None s backgroundToolBarColor",
|
||||
"a c #000000",
|
||||
"# c #1532ed",
|
||||
"........................",
|
||||
"...............#........",
|
||||
"...............##.......",
|
||||
".....#############......",
|
||||
".....##############.....",
|
||||
".....#############......",
|
||||
"...............##.......",
|
||||
"...............#........",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................"};
|
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rregion.xpm
Normal file
30
.emacs.d/elpa/ess-20160208.453/etc/icons/rregion.xpm
Normal file
@@ -0,0 +1,30 @@
|
||||
/* XPM */
|
||||
static char *rregion[]={
|
||||
"24 24 3 1",
|
||||
". c None s backgroundToolBarColor",
|
||||
"a c #000000",
|
||||
"# c #1532ed",
|
||||
"........................",
|
||||
"...............#........",
|
||||
"...............##.......",
|
||||
".....#############......",
|
||||
".....##############.....",
|
||||
".....#############......",
|
||||
"...............##.......",
|
||||
"...............#........",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"...aaaaaaaaaaaaaaaaaa...",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................"};
|
173
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letter_small.xpm
Normal file
173
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letter_small.xpm
Normal file
@@ -0,0 +1,173 @@
|
||||
/* XPM */
|
||||
static char *dummy[]={
|
||||
"25 19 151 2",
|
||||
"Qt c None s backgroundToolBarColor",
|
||||
"#M c #044b83",
|
||||
"#R c #044c86",
|
||||
"#t c #044c87",
|
||||
"ae c #044d87",
|
||||
"an c #044e7f",
|
||||
".o c #044e81",
|
||||
"#l c #044e8d",
|
||||
"ak c #044f84",
|
||||
".B c #044f88",
|
||||
"#m c #044f8e",
|
||||
"am c #045188",
|
||||
".j c #04518b",
|
||||
".O c #045191",
|
||||
"#6 c #04528f",
|
||||
"#O c #045388",
|
||||
".k c #04538c",
|
||||
"#U c #04538e",
|
||||
"#Y c #045392",
|
||||
".l c #045489",
|
||||
"## c #04548c",
|
||||
"#i c #045490",
|
||||
"#v c #045492",
|
||||
"#. c #04558e",
|
||||
"#C c #045593",
|
||||
"#k c #04568d",
|
||||
"#B c #045695",
|
||||
"#G c #045698",
|
||||
".Y c #045795",
|
||||
".R c #045890",
|
||||
"#j c #04598f",
|
||||
".4 c #045995",
|
||||
"aj c #054e7b",
|
||||
"al c #054e89",
|
||||
"#h c #054e8d",
|
||||
"#S c #055188",
|
||||
"#V c #05518d",
|
||||
".m c #055282",
|
||||
".K c #055284",
|
||||
".5 c #055583",
|
||||
".t c #055791",
|
||||
"#u c #055894",
|
||||
".n c #064e86",
|
||||
"#s c #074d76",
|
||||
".p c #074e83",
|
||||
"a. c #074f89",
|
||||
"#a c #074f8a",
|
||||
"af c #075389",
|
||||
"#9 c #07548e",
|
||||
".A c #075592",
|
||||
".F c #075594",
|
||||
"#1 c #075a99",
|
||||
".c c #094d79",
|
||||
".9 c #094f89",
|
||||
".J c #095681",
|
||||
"#A c #0b568d",
|
||||
".s c #0c4f85",
|
||||
"#5 c #0c5188",
|
||||
"#w c #0d5486",
|
||||
".b c #0e4e7d",
|
||||
".N c #105287",
|
||||
".X c #105685",
|
||||
"#H c #115789",
|
||||
"#Z c #13508a",
|
||||
"#2 c #135287",
|
||||
"#F c #195c8a",
|
||||
".i c #1a5c8b",
|
||||
"#8 c #1b5684",
|
||||
"ai c #1b5a81",
|
||||
"ad c #1c5d87",
|
||||
"#P c #1d5c8c",
|
||||
"#r c #1d5f8a",
|
||||
"#N c #1f5b7d",
|
||||
"ao c #1f5c85",
|
||||
"#0 c #205a86",
|
||||
"#n c #206292",
|
||||
".u c #216794",
|
||||
".d c #245b81",
|
||||
".G c #256390",
|
||||
".3 c #265f85",
|
||||
"a# c #266287",
|
||||
"#x c #296286",
|
||||
"#b c #2a5f96",
|
||||
"#g c #2b6395",
|
||||
".a c #2c658f",
|
||||
".Q c #307195",
|
||||
".E c #326897",
|
||||
".S c #356f98",
|
||||
".Z c #35789b",
|
||||
"ag c #396c94",
|
||||
"#I c #3a6a78",
|
||||
"#z c #3f7497",
|
||||
".1 c #3f7c9e",
|
||||
"#J c #427585",
|
||||
"aa c #42768f",
|
||||
"#X c #447ca1",
|
||||
".C c #457b9a",
|
||||
".z c #457ba8",
|
||||
"ac c #48778f",
|
||||
".q c #4e86b0",
|
||||
"#7 c #4f86b5",
|
||||
".6 c #50829b",
|
||||
"#q c #538db5",
|
||||
"#D c #538eb3",
|
||||
".e c #547f91",
|
||||
"ab c #5487a1",
|
||||
"#T c #58859c",
|
||||
"ah c #5983a7",
|
||||
"#c c #5a7d99",
|
||||
".2 c #5b809c",
|
||||
".P c #5d94bb",
|
||||
"#K c #6c91a0",
|
||||
"#4 c #6c99ba",
|
||||
"#L c #6c9cb7",
|
||||
"#o c #7097a7",
|
||||
"ap c #739eb3",
|
||||
".v c #73a7c0",
|
||||
".0 c #7cacc3",
|
||||
"#y c #7faac6",
|
||||
".# c #82a0a8",
|
||||
"#Q c #84aec8",
|
||||
".I c #86a8bd",
|
||||
".L c #89b3cd",
|
||||
"#d c #8aa7b6",
|
||||
"as c #8db2cc",
|
||||
".y c #8db9cd",
|
||||
".h c #8eb5c9",
|
||||
".8 c #8eb9d3",
|
||||
"#W c #8fb2c9",
|
||||
"at c #91b7c8",
|
||||
"#3 c #94b4cb",
|
||||
"ar c #95b7cb",
|
||||
".T c #979798",
|
||||
".U c #99999a",
|
||||
"#f c #99b9cd",
|
||||
".g c #9b9b9b",
|
||||
".V c #9c9c9c",
|
||||
".r c #9cc2d4",
|
||||
".w c #a7c8d0",
|
||||
".x c #a9c8d1",
|
||||
"#p c #a9cbda",
|
||||
".f c #abc5cd",
|
||||
"#E c #abcad6",
|
||||
"aq c #b1d0e0",
|
||||
"au c #b3d2e2",
|
||||
".7 c #b8cfd6",
|
||||
"#e c #baced7",
|
||||
".W c #d4e0e4",
|
||||
".H c #d7e7ed",
|
||||
".M c #dae6ef",
|
||||
".D c #eef8f8",
|
||||
"QtQtQtQt.#.a.b.c.d.e.fQtQtQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"QtQt.h.i.j.k.l.m.n.o.p.qQtQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"Qt.r.s.t.u.v.w.x.y.z.A.B.CQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
".D.E.F.G.HQtQtQtQtQt.I.J.K.LQtQtQtQtQt.g.gQtQtQtQt",
|
||||
".M.N.O.PQtQtQtQtQtQtQt.Q.R.SQt.g.T.U.g.g.g.V.V.g.g",
|
||||
".W.X.Y.ZQtQtQtQtQtQtQt.0.1.2Qt.g.g.g.g.g.g.g.g.g.g",
|
||||
"Qt.3.4.5.6.7QtQtQtQtQtQtQtQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"Qt.8.9#.###a#b#c#d#eQtQtQtQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"QtQt#f#g#h#i#j#k#l#m#n#oQtQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"QtQtQtQt#p#q#r#s#t#u#v#w#xQtQtQtQtQtQt.g.gQtQtQtQt",
|
||||
"QtQtQtQtQtQtQtQt#y#z#A#B#C#DQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQtQtQtQtQtQtQtQtQt#E#F#G#HQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"#I#J#KQtQtQtQtQtQtQtQt#L.B#MQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"#N#O#PQtQtQtQtQtQtQtQt#Q#R#SQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"#T#U#V#WQtQtQtQtQtQtQt#X#Y#ZQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"Qt#0#1#2#3QtQtQtQtQt#4#5#6#7QtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQt#8#9a.a#aaabacadaeafagQtQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQtQtahaiajakalamanaoapQtQtQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQtQtQtQtaqarasatauQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt"};
|
BIN
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letters_large.png
Normal file
BIN
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letters_large.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.2 KiB |
281
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letters_large.xpm
Normal file
281
.emacs.d/elpa/ess-20160208.453/etc/icons/splus_letters_large.xpm
Normal file
@@ -0,0 +1,281 @@
|
||||
/* XPM */
|
||||
static char *splus_letters_large[] = {
|
||||
/* width height num_colors chars_per_pixel */
|
||||
" 51 38 236 2",
|
||||
/* colors */
|
||||
".. c #043e74",
|
||||
".# c #74a29c",
|
||||
".a c #547a74",
|
||||
".b c #bcb2b9",
|
||||
".c c #0c6a9c",
|
||||
".d c #045282",
|
||||
".e c #bcdae8",
|
||||
".f c #94c2cc",
|
||||
".g c #245678",
|
||||
".h c #e4e2e3",
|
||||
".i c #94a2a4",
|
||||
".j c #04528f",
|
||||
".k c #5c8aa4",
|
||||
".l c #346688",
|
||||
".m c #848a8c",
|
||||
".n c #04427c",
|
||||
".o c #e4f4fc",
|
||||
".p c #94b4b4",
|
||||
".q c #cceef4",
|
||||
".r c #045e99",
|
||||
".s c #4c7a88",
|
||||
".t c #a4d6f0",
|
||||
".u c #6c8e94",
|
||||
".v c #f4f2e4",
|
||||
".w c #7cb2d4",
|
||||
".x c #b4b2b4",
|
||||
".y c #145274",
|
||||
".z c #044c74",
|
||||
".A c #acc2d4",
|
||||
".B c #dcdddc",
|
||||
".C c #34729c",
|
||||
".D c #c4c6c4",
|
||||
".E c #144e84",
|
||||
".F c #94b4cc",
|
||||
".G c #fcfaeb",
|
||||
".H c #245a88",
|
||||
".I c #5496b9",
|
||||
".J c #044a80",
|
||||
".K c #c4e6f1",
|
||||
".L c #9cc6ec",
|
||||
".M c #347aac",
|
||||
".N c #6c96a8",
|
||||
".O c #145a80",
|
||||
".P c #6ca2c8",
|
||||
".Q c #045a91",
|
||||
".R c #d4fafc",
|
||||
".S c #145e8c",
|
||||
".T c #144264",
|
||||
".U c #446e89",
|
||||
".V c #949594",
|
||||
".W c #5c7e84",
|
||||
".X c #548ec4",
|
||||
".Y c #e4fdfc",
|
||||
".Z c #044a8c",
|
||||
".0 c #e4eef2",
|
||||
".1 c #a4a3a4",
|
||||
".2 c #346aa0",
|
||||
".3 c #dceef4",
|
||||
".4 c #bcd2d4",
|
||||
".5 c #f4faf9",
|
||||
".6 c #74aacc",
|
||||
".7 c #044669",
|
||||
".8 c #246696",
|
||||
".9 c #045a84",
|
||||
"#. c #ccdedc",
|
||||
"## c #9ccad8",
|
||||
"#a c #a4b6b7",
|
||||
"#b c #144a6e",
|
||||
"#c c #94bacc",
|
||||
"#d c #346288",
|
||||
"#e c #6c9bbc",
|
||||
"#f c #bcbebc",
|
||||
"#g c #c4e2ec",
|
||||
"#h c #0c548c",
|
||||
"#i c #7c9e9c",
|
||||
"#j c #f4f2f4",
|
||||
"#k c #14527c",
|
||||
"#l c #0c4c7f",
|
||||
"#m c #0c5379",
|
||||
"#n c #c4dae4",
|
||||
"#o c #245e7c",
|
||||
"#p c #6492a4",
|
||||
"#q c #346e94",
|
||||
"#r c #ecf4f2",
|
||||
"#s c #44829c",
|
||||
"#t c #b4cad0",
|
||||
"#u c #145a8e",
|
||||
"#v c #447490",
|
||||
"#w c #246294",
|
||||
"#x c #448abc",
|
||||
"#y c #fcfefb",
|
||||
"#z c #2c6f9a",
|
||||
"#A c #a4bacc",
|
||||
"#B c #bcbaba",
|
||||
"#C c #94a6c0",
|
||||
"#D c #04569c",
|
||||
"#E c #648aa0",
|
||||
"#F c #d4f6fc",
|
||||
"#G c #8cb2c4",
|
||||
"#H c #acbabc",
|
||||
"#I c #d4e8f0",
|
||||
"#J c #84aabc",
|
||||
"#K c #1c5b82",
|
||||
"#L c #7ca2c1",
|
||||
"#M c #5486a4",
|
||||
"#N c #ecebe9",
|
||||
"#O c #0c5fa4",
|
||||
"#P c #9cbdce",
|
||||
"#Q c #accee4",
|
||||
"#R c #0c4270",
|
||||
"#S c #6c6e6c",
|
||||
"#T c #a4c4cc",
|
||||
"#U c #0c467c",
|
||||
"#V c #9cb6b4",
|
||||
"#W c #d4eef8",
|
||||
"#X c #447c98",
|
||||
"#Y c #b4d4e8",
|
||||
"#Z c #6c92a4",
|
||||
"#0 c #0c4b6f",
|
||||
"#1 c #cccccc",
|
||||
"#2 c #2c5e8c",
|
||||
"#3 c #649cc0",
|
||||
"#4 c #cce7f1",
|
||||
"#5 c #a4cee8",
|
||||
"#6 c #4482ac",
|
||||
"#7 c #d4d6d4",
|
||||
"#8 c #648abc",
|
||||
"#9 c #9c9b9c",
|
||||
"a. c #acadac",
|
||||
"a# c #547a98",
|
||||
"aa c #34627c",
|
||||
"ab c #1c669c",
|
||||
"ac c #84badc",
|
||||
"ad c #bcced4",
|
||||
"ae c #6c8ea4",
|
||||
"af c #bcd4e8",
|
||||
"ag c #dcf6fc",
|
||||
"ah c #8cbad4",
|
||||
"ai c #7c9bb1",
|
||||
"aj c #9cc6dc",
|
||||
"ak c #3c6a84",
|
||||
"al c #7496a7",
|
||||
"am c #1c5e94",
|
||||
"an c #5c90b8",
|
||||
"ao c #b4dee4",
|
||||
"ap c #4c728c",
|
||||
"aq c #4c86ac",
|
||||
"ar c #dce6e9",
|
||||
"as c #8caebc",
|
||||
"at c #94aec0",
|
||||
"au c #7ca2a8",
|
||||
"av c #5c96c4",
|
||||
"aw c #0c5a90",
|
||||
"ax c #2c668c",
|
||||
"ay c #2c5e70",
|
||||
"az c #5c86a4",
|
||||
"aA c #ece6dc",
|
||||
"aB c #8c8d8f",
|
||||
"aC c #748c8c",
|
||||
"aD c #fcf6ec",
|
||||
"aE c #84b6cc",
|
||||
"aF c #1c5470",
|
||||
"aG c #3c7aa4",
|
||||
"aH c #74a6c4",
|
||||
"aI c #7cacc8",
|
||||
"aJ c #a4cbd7",
|
||||
"aK c #1c4e6c",
|
||||
"aL c #749bc1",
|
||||
"aM c #c4c2c4",
|
||||
"aN c #fcf6f5",
|
||||
"aO c #1c5682",
|
||||
"aP c #b4cbe1",
|
||||
"aQ c #747274",
|
||||
"aR c #4c7a9c",
|
||||
"aS c #04468c",
|
||||
"aT c #94b2c4",
|
||||
"aU c #0462a4",
|
||||
"aV c #84a6b4",
|
||||
"aW c #9ccaf4",
|
||||
"aX c #6c9ab4",
|
||||
"aY c #dcfbfc",
|
||||
"aZ c #14629c",
|
||||
"a0 c #14466c",
|
||||
"a1 c #ecfdfc",
|
||||
"a2 c #dcf2fc",
|
||||
"a3 c #0c5384",
|
||||
"a4 c #c4dcf4",
|
||||
"a5 c #ecf5fc",
|
||||
"a6 c #44749c",
|
||||
"a7 c #2c6ea4",
|
||||
"a8 c #648eac",
|
||||
"a9 c #8cb6d4",
|
||||
"b. c #7ca6cc",
|
||||
"b# c #eceef4",
|
||||
"ba c #a4c6dc",
|
||||
"bb c #9cb2c4",
|
||||
"bc c #b4daf4",
|
||||
"bd c #9ca29c",
|
||||
"be c #c4d2dc",
|
||||
"bf c #3c6e90",
|
||||
"bg c #b4babb",
|
||||
"bh c #4c82a4",
|
||||
"bi c #045a9c",
|
||||
"bj c #044674",
|
||||
"bk c #0c5a84",
|
||||
"bl c #4c829c",
|
||||
"bm c #5486b4",
|
||||
"bn c #044272",
|
||||
"bo c #bcb6b8",
|
||||
"bp c #045684",
|
||||
"bq c #bcdee7",
|
||||
"br c #245a7c",
|
||||
"bs c #e4e6e4",
|
||||
"bt c #045691",
|
||||
"bu c #5c8ea9",
|
||||
"bv c #04467e",
|
||||
"bw c #ccf2f9",
|
||||
"bx c #04629c",
|
||||
"by c #f4f6ec",
|
||||
"bz c #b4b6b5",
|
||||
"bA c #fcfeec",
|
||||
"bB c #245e88",
|
||||
"bC c #044e81",
|
||||
"bD c #9ccae4",
|
||||
"bE c #347ea4",
|
||||
"bF c #5c828c",
|
||||
"bG c #044e8d",
|
||||
"bH c #346e9c",
|
||||
"bI c #dcf2ec",
|
||||
"bJ c #0c6298",
|
||||
"bK c #f4fefc",
|
||||
"bL c #74aec4",
|
||||
"bM c #a4babc",
|
||||
"bN c #94bed4",
|
||||
"bO c #f4f6f4",
|
||||
"bP c #145680",
|
||||
/* pixels */
|
||||
".mbgbobo.bbo#Bbg#aaVa8.l#ba0.7a0br.U.N.p#abg#Bbobobo#B#Bbo.b.bbz#B#Bbg#Bbz#B.V#SaQ#SaB.x#B#B#B#Bbg#B#B",
|
||||
".x.5#yaN#y#yar#a.Way#l#h#hbtaw.d#l#K.gay.uada5#ybO#j#y#yaN#yaN#y#y#y#y#y#y#y#1.V#9.V#BbO#y#y#y#y#y#y#y",
|
||||
"#B#y#ybKagbDaq#u.JbGbtbtbt.QbpbC#h.d.JbC.JbP.X.ta1bK#y#y#y#y#y#y#y#y#y#y#y#y.D#9#9#9#BbO#y#y#y#y#y#y#y",
|
||||
"bo.G#y.oas.lbj.Jbt.Qbt.J.J.9bk.JbvbG.d.dbtbvbvbf#Ta1#y#y#yaN#y#y#y#y#y#y#y#y.D.V#9.V#BbO#y#y#y#y#y#y#y",
|
||||
"#B#y.Yah.8bv.QbJ.j#m#K#X#palal.Na8#qaO#l#Dbt.j.J#zaja1#yaN#y#y#y#y#y#y#y#y#y.D#9#9#9#faN#y#y#y#y#y#y#y",
|
||||
"bg#ybqa6...jbi.J.S#3.tbw.Y.Ya1aY.Rbw.Lbm#ubGbtbC.7ap#n#y#y#yaN#y#y#y#y#y#y#y.D#9.V#9#B#y#y#y#y#y#y#y#y",
|
||||
"bza1b..J.ZbibC.g.F.0#y#y.G#y#y#ybK#y#yb##CaF.d.c.da3.Pa2#yaN.G#y#y#y#y#y#y#y.D#9#9.V#BbO#y#y#y#y#y#y#y",
|
||||
"bz#Ia6..aZ.jbG#ea1#y#y#y#y#y#y#y#y#y#y#y.oaE.y.z.rbjax#Y#yaD.v#N.h.hbsbs.hbs.x#9#9#9.x.h#Nbs.hbs.hbs#j",
|
||||
"#Ha4aObG#DbG#ubabK#y.G#y#y#y#y.5#yaNaNaN#y#W#s.JbxbtbC.6a1#yaAa.#9.1#9.1.1#9#9#9#9#9bd#9.1.1.1#9#9.1.B",
|
||||
"#H.AaObGbGbtab#5bK#y#y.G#y#y#y#y#y#yaN.G#ya1bL.zbt.dbnaz.3#y.h.1aB.V#9aB.V#9#9#9#9#9#9#9.V.V#9.V.V#9.B",
|
||||
"#H#AaO.Q#DbtbkaEa1#y#y.G#y#y#yaN#yaN#yaNaN#y##.O.z#m#Rap#n#ybs.1.V.1#9#9#9.1#9.Vbd#9#9#9#9#9#9.1.V.1.B",
|
||||
"bg#t#KbC.rbt.d#s#WbK#y#y#y#yaN#yaN#y#yaNaNbK#gaIaHaIaibb#I#y#r#1#1#1.D#1#1#1.x#9#9#9a..D#1#1#1#1#1#1b#",
|
||||
"bgaraabjbi.Qbp#mbuaJbI#y#y#y#y#yaNaN#y#y#y#ybK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#1#9.V#9#fbO#y#y#y#y#y#y#y",
|
||||
"bga5.kbCbt.rbx.z.7ak#Z#Pa4.0#y#y#y#y#y#y#y#j#y#y.5#y#y#y#yaN#y#y#y#y#y#y#y#y#f#9#9.V#B#y#y#y#y#y#y#y#y",
|
||||
"bo#y#Qa7.Zbt.r.Q.QbC.Z#h.2#8#C#A.4ar#r#y#y#yaNaN#y#y#y#y#y#yaN#y#y#y#y#y#y#yaM.V#9.V#fbO#y#y#y#y#y#y#y",
|
||||
"bo#y.YaIam..bv.Qbtbtbt#laS#Ra0aKaka#ae#c.ea2bK#y#y#yaN.G#y#y.5#y#y#y#y#y#y#y.D#9bd#9#faN#y#y#y#y#y#y#y",
|
||||
"bo.G#ya5at#d#UaS#D#Dbi.r.r.QbtbtbG.Z.Z.jaban.f#.bO#y#y#y#y#y.5#y#y#y#y#y#y#y.D.V#9.VbobO#y#y#y#y#y#y#y",
|
||||
"boaN#y#ya1bcaLax#U.JbCbGbp.Q.9bt.j.j.j.j.J.zaK.U#Pa2bK#y#y#y#y#y#yaN#y#y#y#y.D.VaBaBbzbO#y#y#y#y#y#y#y",
|
||||
"#B#y#y#yaNbK.oaf#Jan.C.ObCbC.d.d.j.jbi.rbi.j#l#0#KaX#I#y.5.G.G#y#y#y#y#y#y#y#1.xa..1.D#y#y#y#y#y#y#y#y",
|
||||
"bo#y#yaN.5#y#y#ybK#FaW.Paq#o#b.7bv.J#hbt.j.jaZawbnaFaEa1.5aN#y#y#y#y#y#y#y#y.h#7.h.B.h#y#y#y#y#y#y#y#y",
|
||||
"#B#y.G.G#y.G#y.G#y#y.Y#IaoaJ#GaXaq#w#0.Jbtbi#Dbibi.J.MaobK.G.G#y#y#y#y#y#y#yaN#y#yaN#y#yaN#y#y#y#y#y#y",
|
||||
"bg#y#y#y#y#yaN#y#y#ybKbKbKbKbKa1.3#Y.F.kbBbC.dbiaU.jbv#3.o#yaD#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#HbK#y.5#y#y.G.G.G#y#y#y#y#y#y#y#y#y#y.0#Tbha3.j#Dbibv#zaf#y.G#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#Ha1a1a1a1#y.GaN#y#y#y#y#y#y.GaN#y.G#y#y#y.K#Mbj.jbi.jbP#c#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
".a.##i.#au#t#y#yaN#y#y#y#y#y.GaN.G.G.GbA#y#y#P.O.jbt.jbv#LbK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
".T#0#0#0aK#EbK#y#y.G#y#y#y#y#y#y#y#y.G#y#y#y#gaG.JbC.jbn#ebK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"br#m.QbC.JaR.3#yaNaN#y#y#y#y#y#y#y#yaN.GaD.G#Wbhbv.j.Q.JaXbK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#v#0.d.j.J.8#Q#y#y.G#y#y#y#ybK#y#yaN#y#ybObK.ebHbvbtbt#l#LbK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
".NbP.j.r.d#h#LbK#y#y#y#y#ybK#ybKbK#y#y#y#y#y#P.ObGbt.Z.Ea9#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"at.s.Jbt#D.ZaxbabO#y#y#ybK#y#y#y#y#y#y#y#y#4an.Jbt#D.n.2#Y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"bMaT#k.Z#D#O.n.UbeaN#y#y#y#y#y#y#y#y#y#y.0ai.gbC#DbibGav#F#y.G#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#B.0#Ebnbp#ObGbG.8.PbcaYa1a1.YbKbKbKaYaW#x#h.Zbibtbj.2#Q#y#yaN#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"bo#y.e#X.J.j.r#DaS#hbHbFaCau.p#V.iaC.sam.JbG.r#Dbv.HbN.5.5aNaN#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#B#ybKaPa#a0.EbC#h.d.zbC#mawaw#u.S.d.J.d.jbCbC#b#d#G.o#y#j#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"bzbObKa1.KaL#2#la3bCbC.d.j.jbGbvbGbtbt.jbCbj.yblaJ.YbKbKbK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#B#yaN#y#ya5aPaiak#o#mbj.zbC#h.j.d.d.z.7br#M#P#I#y#yaN#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"#B#y#y#yaN#y.5ag.K.t.w.I#6.Ca7a7#zbE.Iacbc.q.Y#y#y#y#y.G#y.5bK#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y",
|
||||
"bo#y#y#y#y.5#y#y#y#y#y#ybO#r#r.5by.5#y#y#y#y#y#y#y#y#y#y#y#ybO#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y#y"
|
||||
};
|
37
.emacs.d/elpa/ess-20160208.453/etc/icons/spluslogo.xpm
Normal file
37
.emacs.d/elpa/ess-20160208.453/etc/icons/spluslogo.xpm
Normal file
@@ -0,0 +1,37 @@
|
||||
/* XPM */
|
||||
static char *spluslogo[]={
|
||||
"24 24 10 1",
|
||||
"a c None s backgroundToolBarColor",
|
||||
"g c #000000",
|
||||
"h c #838383",
|
||||
"# c #ce3000",
|
||||
"f c #ce3062",
|
||||
"e c #ce6262",
|
||||
". c #ce629b",
|
||||
"b c #cecece",
|
||||
"d c #ffcece",
|
||||
"c c #ffceff",
|
||||
".##aaaa###aa#aab#a#ba.##",
|
||||
"#a#caaa#db#a#aab#a#bd#a#",
|
||||
"##caaaa#b#.a#aad#a#ba##c",
|
||||
"a.#a##a##.ca#aab#a#daa.#",
|
||||
"ea#aaaa#daaa#aab#a#bbea#",
|
||||
"##.aaaa#daaa###a.f#ac##.",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa",
|
||||
"aaaaaggga###ahhhaaaaaaaa",
|
||||
"aaaaaggga###ahhhaaaaaaaa",
|
||||
"aaaaaggga###ahhhaaaaaaaa",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa",
|
||||
"aaaaa###ahhhaaaahhhaaaaa",
|
||||
"aaaaa###ahhhaaaahhhaaaaa",
|
||||
"aaaaa###ahhhaaaahhhaaaaa",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa",
|
||||
"aaaaahhhaaaahhha###aaaaa",
|
||||
"aaaaahhhaaaahhha###aaaaa",
|
||||
"aaaaahhhaaaahhha###aaaaa",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa",
|
||||
"aaaaaaaahhha###agggaaaaa",
|
||||
"aaaaaaaahhha###agggaaaaa",
|
||||
"aaaaaaaahhha###agggaaaaa",
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaa"};
|
44
.emacs.d/elpa/ess-20160208.453/etc/icons/spluslogo.xpm.safe
Normal file
44
.emacs.d/elpa/ess-20160208.453/etc/icons/spluslogo.xpm.safe
Normal file
@@ -0,0 +1,44 @@
|
||||
/* XPM */
|
||||
static char *spluslogo[] = {
|
||||
/* width height num_colors chars_per_pixel */
|
||||
" 24 24 13 1",
|
||||
/* colors */
|
||||
". c #000000",
|
||||
"# c #303062",
|
||||
"a c #494949",
|
||||
"b c #626262",
|
||||
"c c #838383",
|
||||
"d c #ce3000",
|
||||
"e c #ce3062",
|
||||
"f c #ce6262",
|
||||
"g c #ce629b",
|
||||
"h c #cecece",
|
||||
"i c #ffcece",
|
||||
"j c #ffceff",
|
||||
"k c None",
|
||||
/* pixels */
|
||||
"gddkkkkdddiidkkhdkdhkgdd",
|
||||
"dkdjkkkdihdidkkhdkdhidkd",
|
||||
"ddjkkkkdhdgidkkidkdhkddj",
|
||||
"kgdkddkddgjidkkhdkdikkgd",
|
||||
"fkdiiikdikkidkkhdkdhhfkd",
|
||||
"ddgkkkkdikkidddkgedkjddg",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk",
|
||||
"kkkkk...kdddkccckkkkkkkk",
|
||||
"kkkkk...kdddkccckkkkkkkk",
|
||||
"kkkkk...kdddkccckkkkkkkk",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk",
|
||||
"kkkkkdddkccckkkkccckkkkk",
|
||||
"kkkkkdddkccckkkkccckkkkk",
|
||||
"kkkkkdddkccckkkkccckkkkk",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk",
|
||||
"kkkkkccckkkkccckdddkkkkk",
|
||||
"kkkkkccckkkkccckdddkkkkk",
|
||||
"kkkkkccckkkkccckdddkkkkk",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk",
|
||||
"kkkkkkkkccckdddk...kkkkk",
|
||||
"kkkkkkkkccckdddk...kkkkk",
|
||||
"kkkkkkkkccckdddk...kkkkk",
|
||||
"kkkkkkkkkkkkkkkkkkkkkkkk"
|
||||
};
|
161
.emacs.d/elpa/ess-20160208.453/etc/icons/startr.xpm
Normal file
161
.emacs.d/elpa/ess-20160208.453/etc/icons/startr.xpm
Normal file
@@ -0,0 +1,161 @@
|
||||
/* XPM */
|
||||
static char *rlogo3[] = {
|
||||
/* width height num_colors chars_per_pixel */
|
||||
" 24 24 130 2",
|
||||
/* colors */
|
||||
".. c None s backgroundToolBarColor",
|
||||
".# c #747684",
|
||||
".a c #acaeac",
|
||||
".b c #8492bc",
|
||||
".c c #94a2c4",
|
||||
".d c #c4cacc",
|
||||
".e c #84868c",
|
||||
".f c #3c424c",
|
||||
".g c #949aac",
|
||||
".h c #bcbec4",
|
||||
".i c #545e74",
|
||||
".j c #d4dae4",
|
||||
".k c #94a2d4",
|
||||
".l c #8492c4",
|
||||
".m c #7486ac",
|
||||
".n c #a4b2d4",
|
||||
".o c #ccd2e4",
|
||||
".p c #9caacc",
|
||||
".q c #8c9ac4",
|
||||
".r c #848eac",
|
||||
".s c #444e64",
|
||||
".t c #949acc",
|
||||
".u c #bcc2ec",
|
||||
".v c #dce2e4",
|
||||
".w c #b4bad4",
|
||||
".x c #5c6674",
|
||||
".y c #d4daec",
|
||||
".z c #9ca2d4",
|
||||
".A c #acbae4",
|
||||
".B c #7c82a4",
|
||||
".C c #6c769c",
|
||||
".D c #d4d2d4",
|
||||
".E c #8c92c4",
|
||||
".F c #7c8eac",
|
||||
".G c #a4b2dc",
|
||||
".H c #545664",
|
||||
".I c #8c92ac",
|
||||
".J c #8c8e94",
|
||||
".K c #949abc",
|
||||
".L c #5c5e74",
|
||||
".M c #7c86ac",
|
||||
".N c #747ea4",
|
||||
".O c #242a34",
|
||||
".P c #9ca2bc",
|
||||
".Q c #8c8a8c",
|
||||
".R c #6c6e7c",
|
||||
".S c #7482b4",
|
||||
".T c #9c9aa4",
|
||||
".U c #b4bedc",
|
||||
".V c #dcdedc",
|
||||
".W c #94a6d4",
|
||||
".X c #8496c4",
|
||||
".Y c #acb2cc",
|
||||
".Z c #ccd2f4",
|
||||
".0 c #8c9ad4",
|
||||
".1 c #848ebc",
|
||||
".2 c #949ed4",
|
||||
".3 c #9ca6dc",
|
||||
".4 c #7c8abc",
|
||||
".5 c #7482a4",
|
||||
".6 c #3c3a3c",
|
||||
".7 c #9ca6bc",
|
||||
".8 c #747a8c",
|
||||
".9 c #acaebc",
|
||||
"#. c #8496b4",
|
||||
"## c #c4cadc",
|
||||
"#a c #545e84",
|
||||
"#b c #747aa4",
|
||||
"#c c #64728c",
|
||||
"#d c #ccd6ec",
|
||||
"#e c #9caadc",
|
||||
"#f c #8c9ecc",
|
||||
"#g c #949ec4",
|
||||
"#h c #bcc6f4",
|
||||
"#i c #9ca6cc",
|
||||
"#j c #8c96c4",
|
||||
"#k c #8c96bc",
|
||||
"#l c #5c6274",
|
||||
"#m c #7c8ab4",
|
||||
"#n c #4c4e6c",
|
||||
"#o c #9c9ea4",
|
||||
"#p c #acb6d4",
|
||||
"#q c #acaeb4",
|
||||
"#r c #848694",
|
||||
"#s c #3c465c",
|
||||
"#t c #bcbecc",
|
||||
"#u c #545e7c",
|
||||
"#v c #d4dee4",
|
||||
"#w c #6c7aa4",
|
||||
"#x c #94a2dc",
|
||||
"#y c #8492cc",
|
||||
"#z c #7486b4",
|
||||
"#A c #646a84",
|
||||
"#B c #9caad4",
|
||||
"#C c #8c9acc",
|
||||
"#D c #848eb4",
|
||||
"#E c #4c4e54",
|
||||
"#F c #bcc6e4",
|
||||
"#G c #5c668c",
|
||||
"#H c #d4deec",
|
||||
"#I c #7c82ac",
|
||||
"#J c #6c7a9c",
|
||||
"#K c #a4aac4",
|
||||
"#L c #d4d6dc",
|
||||
"#M c #a4b2e4",
|
||||
"#N c #545674",
|
||||
"#O c #b4bac4",
|
||||
"#P c #8c96b4",
|
||||
"#Q c #c4c6cc",
|
||||
"#R c #7c86b4",
|
||||
"#S c #2c2e3c",
|
||||
"#T c #bcc2d4",
|
||||
"#U c #ccced4",
|
||||
"#V c #6c727c",
|
||||
"#W c #c4cedc",
|
||||
"#X c #4c526c",
|
||||
"#Y c #747eac",
|
||||
"#Z c #9ca2c4",
|
||||
"#0 c #8c8a94",
|
||||
"#1 c #dcdee4",
|
||||
"#2 c #94a6dc",
|
||||
"#3 c #8496cc",
|
||||
"#4 c #acb2d4",
|
||||
"#5 c #848ec4",
|
||||
"#6 c #dcdef4",
|
||||
"#7 c #7482ac",
|
||||
"#8 c #949ecc",
|
||||
"#9 c #9ca6d4",
|
||||
"a. c #8c96cc",
|
||||
"a# c #5c627c",
|
||||
/* pixels */
|
||||
"................................................",
|
||||
"................................................",
|
||||
".....d.y#H#v.j#v.j#v.y#v#v.j.j#W#F#p............",
|
||||
"....#4.b#J#w#I.P#i#g#Z#8#Z#j#R#Y#ma.#P.j........",
|
||||
".....Y.l.5.X.u.P.i#n.s#n#u#b#8.X.4.4.M#r........",
|
||||
".....Y#y#z.3.G#X.Q.Q.Q#0.J#r#a.b#ja..E.C........",
|
||||
".....Y#y.m.k#8.x.............Y#m.4.2.z.H.T......",
|
||||
".....Y.E.S.k#8#l...............q#z.0.3#N.g......",
|
||||
".....Y.l#z#9.ta#..............#B#Y.k.G.L#Q......",
|
||||
".....Y.E.m.2.t.C............#6.I.F#d.I#s........",
|
||||
".....Y.l#za..l.g#L#1.v#1.o#U#K#P###T#S#o........",
|
||||
".....Y.X#7a.#j.b#C.p.c#..N.C.K#W#r.O.6.D........",
|
||||
".....Y#y#7.2.Z.o.I.B.I#9#f#x#h#s#E#q............",
|
||||
".....Y#j#7.W.u.i.6.f#X#A#j#2#e#X#T..............",
|
||||
".....Y#y.m.k#8#l......#O#G#j#f.F.w..............",
|
||||
".....Y#y#I#x#8#l.........9.N.l#R.1#J#Q..........",
|
||||
".....Y#5#z.k#8#l........#O#c#D#5#5.b.I.V........",
|
||||
"....#4.l#R.k.t#l...........9.N.l#3.E.C.g........",
|
||||
".....Y#y.m#x#8.x.............g.b#3#C.1.C#U......",
|
||||
"....#4.E#k.A#i#l.............7#Y.X#M.p.B.g......",
|
||||
".....Y.1.c.U.K.i..............#G#m.n#p.r.i......",
|
||||
"....#t.8#V#A.R.e...............h.8.R.R.R.#.a....",
|
||||
"................................................",
|
||||
"................................................"
|
||||
};
|
40
.emacs.d/elpa/ess-20160208.453/etc/icons/switch_ess.xpm
Normal file
40
.emacs.d/elpa/ess-20160208.453/etc/icons/switch_ess.xpm
Normal file
@@ -0,0 +1,40 @@
|
||||
/* XPM */
|
||||
static char *switch_ess[]={
|
||||
"24 24 13 1",
|
||||
". c None s backgroundToolBarColor",
|
||||
"a c #000000",
|
||||
"e c #131313",
|
||||
"# c #1532ed",
|
||||
"d c #313131",
|
||||
"k c #434343",
|
||||
"j c #535353",
|
||||
"h c #707070",
|
||||
"b c #878787",
|
||||
"i c #949494",
|
||||
"g c #a0a0a0",
|
||||
"f c #bfbfbf",
|
||||
"c c #c3c3c3",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"........................",
|
||||
"..###...................",
|
||||
"..###...................",
|
||||
"..###...................",
|
||||
"..###.aaaab.cdedc.cdedc.",
|
||||
"..###.af....ag....ag....",
|
||||
"..###.af....ba....ba....",
|
||||
"..###.aaad...fah...fah..",
|
||||
"..###.af.......ga....ga.",
|
||||
"..###.af....i..jk.i..jk.",
|
||||
"..###.aaaak.jeej..jeej..",
|
||||
"..###...................",
|
||||
"..###...................",
|
||||
"..###...................",
|
||||
"..###...........#.......",
|
||||
"..###...........##......",
|
||||
"..#################.....",
|
||||
"..##################....",
|
||||
"...################.....",
|
||||
"................##......",
|
||||
"................#......."};
|
112
.emacs.d/elpa/ess-20160208.453/etc/icons/switchr.xpm
Normal file
112
.emacs.d/elpa/ess-20160208.453/etc/icons/switchr.xpm
Normal file
@@ -0,0 +1,112 @@
|
||||
/* XPM */
|
||||
static char *rt4[]={
|
||||
"24 24 85 2",
|
||||
"Qt c None s backgroundToolBarColor",
|
||||
".V c #14162c",
|
||||
".A c #1c263c",
|
||||
"#d c #24263c",
|
||||
".K c #242e44",
|
||||
".H c #2c3244",
|
||||
"#o c #2c3644",
|
||||
".Q c #34364c",
|
||||
".Z c #3c3e54",
|
||||
".N c #3c4264",
|
||||
".q c #444664",
|
||||
".p c #444a64",
|
||||
"#. c #444e64",
|
||||
".r c #4c4e6c",
|
||||
".w c #4c566c",
|
||||
"#m c #545e74",
|
||||
"#j c #546284",
|
||||
".B c #54628c",
|
||||
"#e c #5c6284",
|
||||
".4 c #5c6a9c",
|
||||
"#k c #646a8c",
|
||||
"#p c #646e8c",
|
||||
".5 c #646e9c",
|
||||
".S c #647294",
|
||||
".b c #647a94",
|
||||
".c c #6c769c",
|
||||
".h c #6c7aa4",
|
||||
".3 c #6c7ea4",
|
||||
".k c #747ea4",
|
||||
".O c #7482b4",
|
||||
".u c #7482bc",
|
||||
".i c #7486b4",
|
||||
".X c #7c82a4",
|
||||
".d c #7c86a4",
|
||||
".g c #7c86ac",
|
||||
"#b c #7c86b4",
|
||||
".E c #7c86bc",
|
||||
"#h c #7c8abc",
|
||||
".L c #7c8ac4",
|
||||
".a c #7c8eb4",
|
||||
"## c #848eac",
|
||||
".# c #848ebc",
|
||||
".2 c #8492b4",
|
||||
".m c #8492bc",
|
||||
".l c #8492c4",
|
||||
".I c #8492cc",
|
||||
".t c #8496c4",
|
||||
".f c #8c92b4",
|
||||
".v c #8c92c4",
|
||||
".W c #8c92cc",
|
||||
".7 c #8c96a4",
|
||||
".e c #8c96bc",
|
||||
".F c #8c96c4",
|
||||
"#l c #8c96cc",
|
||||
".y c #8c9ac4",
|
||||
".C c #8c9ad4",
|
||||
"#f c #8c9ed4",
|
||||
".1 c #949ac4",
|
||||
".0 c #949ad4",
|
||||
".D c #949ecc",
|
||||
"#g c #94a2d4",
|
||||
".Y c #9ca6c4",
|
||||
".j c #9caadc",
|
||||
"#a c #9caae4",
|
||||
".J c #a4aae4",
|
||||
".T c #a4aed4",
|
||||
".P c #a4aee4",
|
||||
"#i c #a4b2ec",
|
||||
".9 c #acaebc",
|
||||
".s c #acb2e4",
|
||||
"#n c #acb2ec",
|
||||
".G c #acb6e4",
|
||||
".M c #b4baf4",
|
||||
".o c #b4bedc",
|
||||
"#c c #b4bef4",
|
||||
"#s c #b4c6ec",
|
||||
".n c #bcc2ec",
|
||||
".z c #bcc2fc",
|
||||
".U c #c4cef4",
|
||||
".6 c #ccd2ec",
|
||||
".8 c #ccd2fc",
|
||||
".R c #ccd6ec",
|
||||
"#r c #d4defc",
|
||||
"#q c #d4e2fc",
|
||||
".x c #1532ed",
|
||||
"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt",
|
||||
"QtQtQtQtQtQtQt.#.a.b.c.d.e.e.e.f.g.h.i.j.kQtQtQt",
|
||||
"QtQtQtQtQtQtQt.l.i.m.n.o.p.q.q.r.g.s.t.u.v.wQtQt",
|
||||
"QtQt.x.x.xQtQt.m.i.y.z.AQtQtQtQtQt.B.#.C.D.rQtQt",
|
||||
"QtQt.x.x.xQtQt.m.E.F.G.HQtQtQtQtQtQt.m.I.J.rQtQt",
|
||||
"QtQt.x.x.xQtQt.#.i.t.s.KQtQtQtQtQtQt.D.L.M.NQtQt",
|
||||
"QtQt.x.x.xQtQt.#.O.y.P.QQtQtQtQtQt.R.S.T.U.VQtQt",
|
||||
"QtQt.x.x.xQtQt.#.i.t.W.FQtQtQtQtQt.X.Y.U.ZQtQtQt",
|
||||
"QtQt.x.x.xQtQt.#.i.m.0.1.t.2.3.4.5.6.7.VQtQtQtQt",
|
||||
"QtQt.x.x.xQtQt.#.i.l.8.9.Q#.##.P#a.GQtQtQtQtQtQt",
|
||||
"QtQt.x.x.xQtQt.##b.t#c#dQtQtQt#e#f#g.SQtQtQtQtQt",
|
||||
"QtQt.x.x.xQtQt.##h.t#i.KQtQtQtQt#b.m#h.aQtQtQtQt",
|
||||
"QtQt.x.x.xQtQt.#.O.t#i.KQtQtQtQt#j.#.l.l#kQtQtQt",
|
||||
"QtQt.x.x.xQtQt.F.O.y.s.HQtQtQtQtQt#b.l#l.##mQtQt",
|
||||
"QtQt.x.x.xQtQt.##b.F#n#oQtQtQtQtQt#j.F#f.m#pQtQt",
|
||||
"QtQt.x.x.xQtQt.#.t#q#r.KQtQtQtQtQtQt.i#s#q.YQtQt",
|
||||
"QtQt.x.x.xQtQtQtQtQtQtQtQtQtQtQt.xQtQtQtQtQtQtQt",
|
||||
"QtQt.x.x.xQtQtQtQtQtQtQtQtQtQtQt.x.xQtQtQtQtQtQt",
|
||||
"QtQt.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.xQtQtQtQtQt",
|
||||
"QtQt.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.xQtQtQtQt",
|
||||
"QtQtQt.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.xQtQtQtQtQt",
|
||||
"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt.x.xQtQtQtQtQtQt",
|
||||
"QtQtQtQtQtQtQtQtQtQtQtQtQtQtQtQt.xQtQtQtQtQtQtQt"};
|
32
.emacs.d/elpa/ess-20160208.453/etc/icons/switchs.xpm
Normal file
32
.emacs.d/elpa/ess-20160208.453/etc/icons/switchs.xpm
Normal file
@@ -0,0 +1,32 @@
|
||||
/* XPM */
|
||||
static char *switchs[]={
|
||||
"24 24 5 1",
|
||||
". c None",
|
||||
"# c #000000",
|
||||
"c c #1532ed",
|
||||
"b c #838383",
|
||||
"a c #ce3000",
|
||||
"........................",
|
||||
"........###.aaa.bbb.....",
|
||||
"........###.aaa.bbb.....",
|
||||
"........###.aaa.bbb.....",
|
||||
"..ccc...................",
|
||||
"..ccc...aaa.bbb....bbb..",
|
||||
"..ccc...aaa.bbb....bbb..",
|
||||
"..ccc...aaa.bbb....bbb..",
|
||||
"..ccc...................",
|
||||
"..ccc...bbb....bbb.aaa..",
|
||||
"..ccc...bbb....bbb.aaa..",
|
||||
"..ccc...bbb....bbb.aaa..",
|
||||
"..ccc...................",
|
||||
"..ccc......bbb.aaa.###..",
|
||||
"..ccc......bbb.aaa.###..",
|
||||
"..ccc......bbb.aaa.###..",
|
||||
"..ccc...................",
|
||||
"..ccc...........c.......",
|
||||
"..ccc...........cc......",
|
||||
"..ccccccccccccccccc.....",
|
||||
"..cccccccccccccccccc....",
|
||||
"...cccccccccccccccc.....",
|
||||
"................cc......",
|
||||
"................c......."};
|
25
.emacs.d/elpa/ess-20160208.453/etc/in-string-bug-ex.Rnw
Normal file
25
.emacs.d/elpa/ess-20160208.453/etc/in-string-bug-ex.Rnw
Normal file
@@ -0,0 +1,25 @@
|
||||
% From: Richard Morrisroe <richie.morrisroe@gmail.com>
|
||||
% To: <ess-help@r-project.org>
|
||||
% Subject: Re: [ESS] noweb file and assignment key
|
||||
% Date: Tue, 30 Oct 2012 20:57:32 +0000
|
||||
|
||||
\documentclass{article}
|
||||
|
||||
\begin{document}
|
||||
|
||||
<<packages, echo=FALSE, results=hide>>=
|
||||
i.can.haz.assginment <- TRUE
|
||||
@
|
||||
|
||||
Now, we will introduce an extraneous apostrophe, for no reason '
|
||||
|
||||
<<test2>>=
|
||||
aa <- _2 #ess-smart-underscore-no-longer-works
|
||||
@
|
||||
|
||||
'
|
||||
<<test3, echo=TRUE, results=verbatim >>=
|
||||
nowitdoes <- cat("Note the apostrophe above which closes the earlier one\n")
|
||||
@
|
||||
|
||||
\end{document}
|
72
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/README
Normal file
72
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/README
Normal file
@@ -0,0 +1,72 @@
|
||||
spread We have designed and constructed an interactive spreadsheet
|
||||
interface to S/Splus that maintains the complete power and
|
||||
generality of the S language. At user level, the interface
|
||||
behaves like the popular spreadsheet programs available for
|
||||
personal computers: one or more S data objects (matrices or
|
||||
three-way arrays) are displayed on the screen. The user
|
||||
graphically (with mouse or cursor motion) identifies a cell
|
||||
for review, and possible updating, of its contents. Macros
|
||||
containing arbitrary S expressions can be associated with
|
||||
the entire spread.frame or one of its cells. The
|
||||
spreadsheet is designed in a modular fashion with
|
||||
device-specific methods for the display and updating of
|
||||
spreadsheet objects. We include methods for two devices:
|
||||
the generic S graphics device and a character based device
|
||||
using the emacs 19 environment.
|
||||
Richard M. Heiberger (rmh@astro.ocis.temple.edu)
|
||||
Magnus Mengelbier (magnus@astro.ocis.temple.edu)
|
||||
|
||||
The interface is described in
|
||||
\item Heiberger, Richard M., and Magnus Mengelbier (1995, to appear)
|
||||
``Design of a Spreadsheet Interface for S,''
|
||||
{\it Proceedings of the American Statistical Association},
|
||||
Section on Statistical Graphics.
|
||||
|
||||
This is placeholder announcement. The files will be
|
||||
available on statlib after one more level of testing.
|
||||
|
||||
|
||||
Files in this distribution:
|
||||
README Abstract, file listing, and setup instructions.
|
||||
sprd3d.how Instructions for spread.frame users.
|
||||
|
||||
|
||||
sprd-emc.s S for emacs driver
|
||||
sprd-grd.s S for class="grade"
|
||||
sprd-spr.s S for class="spread" This is the primary set of functions.
|
||||
sprd-txt.s S for graphics device driver based on text() command.
|
||||
|
||||
sprd-int.el emacs lisp file
|
||||
Load this file into emacs 19 each time you start a
|
||||
spread.frame session.
|
||||
|
||||
gradexmp.s S example
|
||||
|
||||
|
||||
|
||||
Setup Instructions
|
||||
|
||||
|
||||
The emacs spreadsheet interface for S consists of four S files
|
||||
"sprd-*.s" and one emacs lisp file "sprd-int.el".
|
||||
|
||||
1. Create a new directory to store the four S files "sprd-*.s" and one
|
||||
emacs lisp file "sprd-int.el". I use "/disk5/rmh/sprd3d/". You might
|
||||
wish to place it under the directory where you store other S/Splus
|
||||
libraries.
|
||||
|
||||
2. Make a new .Data, "/disk5/rmh/sprd3d/.Data", start S/Splus, and
|
||||
source the four sprd-*.s files:
|
||||
|
||||
> source("sprd-emc.s")
|
||||
> source("sprd-grd.s")
|
||||
> source("sprd-spr.s")
|
||||
> source("sprd-txt.s")
|
||||
> q()
|
||||
|
||||
3. The directory /disk5/rmh/sprd3d/ should now be treated as a
|
||||
library directory and should not be further touched. All further work
|
||||
using the spread.frames should be done in a different directory.
|
||||
|
||||
4. See the file sprd3d.how for user instructions. You may look at
|
||||
the file "gradexmp.s" for an example.
|
337
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/S-spread.el
Normal file
337
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/S-spread.el
Normal file
@@ -0,0 +1,337 @@
|
||||
;; spreadsheet in S, S-mode or stand-alone
|
||||
;; Richard M. Heiberger
|
||||
;; 1996
|
||||
|
||||
;; S-mode
|
||||
;; Load this file from a running *S* window after starting S/Splus with M-x S
|
||||
;; or
|
||||
;; stand-alone
|
||||
;; Load this file from the dired window in which .Data exists.
|
||||
|
||||
|
||||
;(set-variable 'buffers-menu-max-size nil)
|
||||
|
||||
|
||||
(defvar spread-directory (concat "/tmp/" (make-temp-name "spr"))
|
||||
"Directory in which to store ascii spreadsheet displays.")
|
||||
|
||||
(defvar spread-command-file (concat spread-directory "/*command*")
|
||||
"File through which S will communicate with emacs.")
|
||||
|
||||
(defvar spread-directory-p nil
|
||||
"predicate value non-nil when directory has been defined.")
|
||||
|
||||
(defun print-find-emacs nil "display spread.frame from minibuffer" (interactive)
|
||||
(spread-print-find (read-string "spread.frame: ") t))
|
||||
|
||||
|
||||
(defun emacs-rc nil "" (interactive)
|
||||
(emacs-cell "1")
|
||||
)
|
||||
|
||||
(defun emacs-macro nil "" (interactive)
|
||||
(emacs-cell "2")
|
||||
)
|
||||
|
||||
(defun emacs-macro-control-text nil "" (interactive)
|
||||
(emacs-cell "4")
|
||||
)
|
||||
|
||||
(defun emacs-macro-print-text nil "" (interactive)
|
||||
(emacs-cell "5")
|
||||
)
|
||||
|
||||
(defun emacs-cell (result-type) "" (interactive)
|
||||
(setq spread-name (buffer-name))
|
||||
(setq r (count-lines 1 (point)))
|
||||
(setq c (current-column))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert
|
||||
(format "emacs.cell('%s', %s, %s, %s)"
|
||||
spread-name r c result-type
|
||||
)
|
||||
)
|
||||
(save-excursion
|
||||
(set-buffer "*command*")
|
||||
(revert-t-t)
|
||||
(goto-char (point-min))
|
||||
(setq beg (point)) (end-of-line)
|
||||
(if (equal result-type "4")
|
||||
(progn
|
||||
(setq command (buffer-substring beg (point)))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert command)
|
||||
)
|
||||
(setq command (read-string "> " (buffer-substring beg (point))))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert command)
|
||||
(spread-insert "invisible(assign(.Active, x))")
|
||||
(spread-print-find spread-name nil)
|
||||
(goto-line r)(forward-char c)
|
||||
))
|
||||
)
|
||||
|
||||
(defun spread-insert (spread-command) "" (interactive)
|
||||
(goto-char (point-max))
|
||||
(insert spread-command)
|
||||
(comint-send-input)
|
||||
(accept-process-output spread-process)
|
||||
)
|
||||
|
||||
(defun revert-t-t nil "revert-buffer with no questions asked"
|
||||
(interactive)
|
||||
(revert-buffer t t)
|
||||
)
|
||||
|
||||
(defun revert-t-t-read-only nil "revert-buffer, no questions, read-only"
|
||||
(interactive)
|
||||
(revert-buffer t t)
|
||||
(setq buffer-read-only t)
|
||||
)
|
||||
|
||||
|
||||
(defvar spread-mode-map nil "Keymap for Spread mode.")
|
||||
(if spread-mode-map
|
||||
nil
|
||||
(setq spread-mode-map (make-sparse-keymap))
|
||||
(define-key spread-mode-map "\C-cv" 'revert-t-t-read-only)
|
||||
(define-key spread-mode-map "\C-m" 'emacs-rc)
|
||||
(define-key spread-mode-map "\C-cc" 'emacs-macro)
|
||||
(define-key spread-mode-map "\C-cs" 'emacs-macro-control-text)
|
||||
(define-key spread-mode-map "\C-cp" 'emacs-macro-print-text)
|
||||
(define-key spread-mode-map "f" 'emacs-print-find-emacs)
|
||||
|
||||
(define-key spread-mode-map [mouse-2] 'spread-mouse-print-find-emacs)
|
||||
(define-key spread-mode-map [mouse-3] 'spread-mouse-rc)
|
||||
)
|
||||
|
||||
(defun spread-mouse-rc (event) "move point then enter"
|
||||
(interactive "e")
|
||||
(mouse-set-point event)
|
||||
(emacs-rc)
|
||||
)
|
||||
|
||||
(defun spread-mouse-print-find-emacs (event) "move point then find file"
|
||||
(interactive "e")
|
||||
(mouse-set-point event)
|
||||
(emacs-print-find-emacs)
|
||||
)
|
||||
|
||||
(defun spread-mode () "Major mode for spreadsheets.\\{spread-mode-map}"
|
||||
(interactive)
|
||||
(kill-all-local-variables)
|
||||
(make-local-variable 'beg)
|
||||
(make-local-variable 'command)
|
||||
(use-local-map spread-mode-map)
|
||||
(setq mode-name "Spread")
|
||||
(setq major-mode 'spread-mode)
|
||||
(if (equal (buffer-name) ".Registry") (spread-highlight-macro))
|
||||
(setq buffer-read-only t)
|
||||
)
|
||||
|
||||
|
||||
;; from dired.el L547
|
||||
; (put-text-property (point)
|
||||
; (save-excursion
|
||||
; (dired-move-to-end-of-filename)
|
||||
; (point))
|
||||
; 'mouse-face 'highlight)
|
||||
;
|
||||
;; (put-text-property (point) (mark) 'mouse-face 'highlight)
|
||||
|
||||
|
||||
(defun spread-highlight-macro nil
|
||||
"highlight spread.frame names for mouse access"
|
||||
(interactive)
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(search-forward "**macro**")(forward-char)
|
||||
|
||||
(toggle-read-only -1)
|
||||
(while (progn
|
||||
(setq beg (point))(end-of-line)
|
||||
(not (= beg (point)))
|
||||
)
|
||||
(put-text-property beg (1-(point)) 'mouse-face 'highlight)
|
||||
(forward-char)
|
||||
)
|
||||
(toggle-read-only 1)
|
||||
)
|
||||
(save-buffer)
|
||||
)
|
||||
|
||||
(defun emacs-print-find-emacs nil "" (interactive)
|
||||
(beginning-of-line)
|
||||
(setq beg (point)) (end-of-line) (backward-char)
|
||||
(setq spread-name (buffer-substring beg (point)))
|
||||
(spread-print-find spread-name nil)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
(defun find-spread-frame-directory nil
|
||||
"Locate directory in which spread.frame functions are stored."
|
||||
(list-command-history)
|
||||
(set-buffer "*Command History*")
|
||||
(goto-char (point-min))
|
||||
(search-forward "(load-file ")
|
||||
(goto-char (1+ (match-end 0)))(setq beg (point))
|
||||
(end-of-line)(search-backward "/")
|
||||
(goto-char (match-end 0))
|
||||
(setq spread-frame-directory
|
||||
(expand-file-name (buffer-substring beg (point))))
|
||||
(kill-buffer "*Command History*")
|
||||
)
|
||||
|
||||
(defvar inferior-spread-mode nil
|
||||
"Non-nil if using inferior-spread-mode as a minor mode of some other mode.")
|
||||
(make-variable-buffer-local 'inferior-spread-mode)
|
||||
(put 'inferior-spread-mode 'permanent-local t)
|
||||
(or (assq 'inferior-spread-mode minor-mode-alist)
|
||||
(setq minor-mode-alist (append minor-mode-alist
|
||||
(list '(inferior-spread-mode " spread")))))
|
||||
|
||||
(defvar inferior-spread-mode-map nil)
|
||||
(if inferior-spread-mode-map
|
||||
nil
|
||||
(setq inferior-spread-mode-map (make-sparse-keymap))
|
||||
(define-key inferior-spread-mode-map "\C-cv" 'revert-t-t)
|
||||
(define-key inferior-spread-mode-map "\C-cr" 'print-find-emacs))
|
||||
|
||||
|
||||
(or (assq 'inferior-spread-mode minor-mode-map-alist)
|
||||
(setq minor-mode-map-alist
|
||||
(cons (cons 'inferior-spread-mode inferior-spread-mode-map)
|
||||
minor-mode-map-alist)))
|
||||
|
||||
(defun inferior-spread-mode (&optional arg)
|
||||
"Toggle Inferior Spread mode.
|
||||
With arg, turn Inferior Spread mode on if arg is positive, off otherwise."
|
||||
(interactive "P")
|
||||
(setq inferior-spread-mode
|
||||
(if (null arg) (not inferior-spread-mode)
|
||||
(> (prefix-numeric-value arg) 0)))
|
||||
(if inferior-spread-mode
|
||||
(progn
|
||||
(set-process-filter spread-process 'comint-output-filter)
|
||||
(set-variable 'comint-output-filter-functions
|
||||
'(spread-output-filter
|
||||
comint-postoutput-scroll-to-bottom))
|
||||
(set-variable 'comint-scroll-to-bottom-on-output "this")
|
||||
(set-variable 'comint-scroll-show-maximum-output t)
|
||||
(force-mode-line-update))
|
||||
(message "Don't know how to turn off Inferior Spread mode")))
|
||||
|
||||
|
||||
(defun spread-process ()
|
||||
"Start stand-alone S process to run spread."
|
||||
(comint-run S-program)
|
||||
(setq spread-process (get-buffer-process (current-buffer)))
|
||||
(setq comint-prompt-regexp shell-prompt-pattern)
|
||||
(if (not(file-writable-p ".Data/.Audit"))
|
||||
(accept-process-output spread-process))
|
||||
(accept-process-output spread-process)
|
||||
spread-process
|
||||
)
|
||||
|
||||
(defun spread-output-filter (str)
|
||||
"detect errors in S output"
|
||||
(if (or
|
||||
(string-match "Dumped" str)
|
||||
(string-match "Error" str)
|
||||
)
|
||||
(progn
|
||||
(switch-to-buffer-other-window S-buffer)
|
||||
(comint-show-maximum-output)
|
||||
(set-variable 'quit-flag t); beeps and writes "quit" in the message area
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
(defun spread-print-find (spread-name update-Registry)
|
||||
"Place SPREAD-NAME in foreground of S-buffer (*S* or *Splus*),
|
||||
update .Registry and revert buffer when UPDATE-REGISTRY is t,
|
||||
print all views of spread.frame associated with SPREAD-NAME in .Registry
|
||||
to /tmp/spr***** directory, and find or revert all views into emacs buffers."
|
||||
(interactive)
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert
|
||||
(format "print.find.emacs('%s', update.Registry=%s)"
|
||||
spread-name (if update-Registry "T" "F")))
|
||||
(if update-Registry
|
||||
(save-excursion (spread-find-file ".Registry")))
|
||||
(spread-print-sprds)
|
||||
(switch-to-buffer spread-name)
|
||||
)
|
||||
|
||||
(defun spread-print-sprds () "Display in buffers all views of spread.frame"
|
||||
(interactive)
|
||||
(save-excursion
|
||||
(set-buffer "*command*")
|
||||
(revert-t-t)
|
||||
(goto-char (point-min))
|
||||
|
||||
(while (< (point) (point-max))
|
||||
(set-buffer "*command*")
|
||||
(setq beg (point)) (end-of-line)
|
||||
(setq spread-name-i (buffer-substring beg (point)))
|
||||
(save-excursion (spread-find-file spread-name-i))
|
||||
(forward-line)))
|
||||
)
|
||||
|
||||
(defun spread-find-file (spread-name) "Display one view of spread.frame"
|
||||
(interactive)
|
||||
(switch-to-buffer spread-name)
|
||||
(if (buffer-file-name)
|
||||
(revert-t-t-read-only)
|
||||
(kill-buffer spread-name)
|
||||
(find-file (concat spread-directory "/" spread-name))
|
||||
)
|
||||
(spread-mode)
|
||||
)
|
||||
|
||||
|
||||
(defun spread-start () "load emacs spread.frame handler"
|
||||
|
||||
(if (equal major-mode 'inferior-S-mode)
|
||||
(progn
|
||||
(setq spread-mode "S-mode")
|
||||
(setq S-buffer (current-buffer)))
|
||||
(if (equal major-mode 'dired-mode)
|
||||
(progn
|
||||
(setq spread-mode "stand-alone")
|
||||
(setq S-program (read-string "Splus or S? " "Splus"))
|
||||
(setq S-buffer (concat "*" (file-name-nondirectory S-program) "*"))
|
||||
(if (not (get-buffer S-buffer))
|
||||
(get-buffer-create S-buffer))
|
||||
(if (get-buffer-process S-buffer) (set-variable 'quit-flag t)))
|
||||
(set-variable 'quit-flag t)))
|
||||
|
||||
(setq spread-home-directory default-directory)
|
||||
(find-spread-frame-directory)
|
||||
(if (not spread-directory-p)
|
||||
(progn (make-directory spread-directory)
|
||||
(setq spread-directory-p t)))
|
||||
(set-buffer S-buffer)
|
||||
(cd spread-home-directory)
|
||||
(setq spread-process
|
||||
(if (equal spread-mode "stand-alone")
|
||||
(spread-process)
|
||||
(get-buffer-process (current-buffer))))
|
||||
(inferior-spread-mode 1)
|
||||
(spread-insert
|
||||
(format "assign('.spread.Data',attach('%s.Data'),frame=0)"
|
||||
spread-frame-directory))
|
||||
(spread-insert
|
||||
(format "emacs.start('%s')" spread-directory))
|
||||
(find-file spread-command-file)
|
||||
(spread-find-file ".Registry")
|
||||
)
|
||||
|
||||
;; start it up
|
||||
(spread-start)
|
BIN
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/S-spread.elc
Normal file
BIN
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/S-spread.elc
Normal file
Binary file not shown.
30845
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/asaprc.ps
Normal file
30845
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/asaprc.ps
Normal file
File diff suppressed because it is too large
Load Diff
18
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/gradexmp.s
Normal file
18
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/gradexmp.s
Normal file
@@ -0,0 +1,18 @@
|
||||
who <- c(
|
||||
"Aaaaa",
|
||||
"Bbbbb",
|
||||
"Cccc",
|
||||
"Zzzzzzz",
|
||||
"maximum")
|
||||
|
||||
what <- c("1a","1b","1c","1d","1e","1f","1g",
|
||||
"1h","2a","2b","2c")
|
||||
|
||||
x <- matrix(0, length(who), length(what),
|
||||
dimnames=list(who,what))
|
||||
|
||||
x["maximum",] <- c(5,5,6,4,20,6,16,8,10,10,10)
|
||||
|
||||
section.7 <- as.grade(x)
|
||||
|
||||
|
280
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-emc.s
Normal file
280
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-emc.s
Normal file
@@ -0,0 +1,280 @@
|
||||
#-*-Fundamental-*-
|
||||
|
||||
|
||||
col.spacing <- function(x)
|
||||
{
|
||||
rn.w <- if (length(dimnames(x)[[1]]) > 0) max(nchar(dimnames(x)[[1]]))
|
||||
else nchar(as.character(nrow(x)))+3
|
||||
col.w <- apply(x, 2, function(x) nchar(format(x))[1])
|
||||
dn.w <- if (length(dimnames(x)[[2]]) > 0) nchar(dimnames(x)[[2]])
|
||||
else nchar(as.character(ncol(x)))+3
|
||||
col.w <- ifelse( col.w > dn.w , col.w, dn.w)
|
||||
cumsum(c(rn.w,col.w)+1)
|
||||
}
|
||||
|
||||
emacs.expr <- function(x, i, j=i[2], result.type)
|
||||
# 1. emacs.rc
|
||||
# 2. emacs.macro
|
||||
# 3. emacs.macro.text(deparse.result=T) #default for index.value
|
||||
# 4. emacs.macro.text(deparse.result=F)
|
||||
# 1. assign expression to cell or to macro
|
||||
# 2. evaluate macro expression
|
||||
# 3. retrieve macro expression
|
||||
# 4. construct control.text() expression from macro name
|
||||
# 5. construct print.text() expression from macro name
|
||||
{
|
||||
# i and j are integer scalars
|
||||
|
||||
if (missing(j)) {j <- i[2] ; i <- i[1]}
|
||||
|
||||
if ((.Active == .Active.buffer) && (length(dim(x)) > 2))
|
||||
stop("Must use rectangular slice, not 3d buffer")
|
||||
|
||||
if (i <= nrow(x) && result.type==1)
|
||||
return(expr.rc(x, c(i, j)))
|
||||
|
||||
if (!inherits(x, "spread")) stop("Not a spread.frame")
|
||||
mm <- (nrow(x)+1):(nrow(x)+2+length(macro(x)))
|
||||
bb <- mm[length(mm)]+(1:(2+length(before(x))))
|
||||
aa <- bb[length(bb)]+(1:(2+length(after(x))))
|
||||
|
||||
find.expr <- function(type.x, kk, type, result.type)
|
||||
{
|
||||
if (kk>0) {
|
||||
iv <- index.value(names(type.x), kk,
|
||||
!((result.type == 4) || (result.type == 5)))
|
||||
switch(result.type,
|
||||
paste(type, "(x)[", iv, "] <- expression(",
|
||||
expr.value(type.x[kk],1), ")"),
|
||||
paste("x <- eval.spread(x, ", type, "(x)[", iv, "] )" ),
|
||||
deparse(eval(parse(text=paste(type, "(x)[", iv, "]")))[[1]]),
|
||||
paste(iv, "<- control.text(", iv, ")"),
|
||||
paste(iv, "<- print.text(", iv, ")")
|
||||
)
|
||||
}
|
||||
else if (result.type==1) paste(type, "(x)[\"\"] <- expression()")
|
||||
else NULL
|
||||
}
|
||||
|
||||
k <- match(i, mm, 0)
|
||||
if (k) return(find.expr(macro(x), k-2, "macro", result.type))
|
||||
|
||||
k <- match(i, bb, 0)
|
||||
if (k) return(find.expr(before(x), k-2, "before", result.type))
|
||||
|
||||
k <- match(i, aa, 0)
|
||||
if (k) return(find.expr(after(x), k-2, "after", result.type))
|
||||
}
|
||||
|
||||
cell.rc.emacs <- function(x, e.r, e.c)
|
||||
{
|
||||
x.r <- ifelse(e.c == 0, e.r, e.r-1)
|
||||
x.c <- sum(e.c >= col.spacing(x))
|
||||
c(row=x.r, col=x.c)
|
||||
}
|
||||
|
||||
print.update.emacs <- function(x, ...,
|
||||
file=paste(.spread.directory, .Active.buffer, sep="/"))
|
||||
{
|
||||
sink(file)
|
||||
print(x, ...)
|
||||
|
||||
xs <- get(.Active)
|
||||
if (inherits(xs, "spread"))
|
||||
{
|
||||
print.spread.macro(xs, macro)
|
||||
print.spread.macro(xs, before)
|
||||
print.spread.macro(xs, after)
|
||||
}
|
||||
|
||||
sink()
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
print.spread.macro <- function(x, macro)
|
||||
{
|
||||
cat("\n**", as.character(substitute(macro)), "**\n", sep="")
|
||||
ne <- names(macro(x))
|
||||
if (length(ne))
|
||||
for (i in 1:length(ne))
|
||||
cat(index.value(ne,i,F),"\n")
|
||||
}
|
||||
|
||||
|
||||
as.two.way.array <- function(x, subs=parse(text=.Active.buffer)[[1]][-(1:2)])
|
||||
{
|
||||
if (length(dim(x))==2) return(x)
|
||||
# This is designed for 3 way arrays with
|
||||
# two missing and one specified dimension.
|
||||
# If the drop parameter exists, it is over-ridden.
|
||||
subs$drop <- NULL
|
||||
which.subs <- (sapply(subs,length)==0)
|
||||
dnx <- dimnames(x)[which.subs]
|
||||
dimnames(x) <- NULL
|
||||
dim(x) <- dim(x)[which.subs]
|
||||
dimnames(x) <- dnx
|
||||
x
|
||||
}
|
||||
|
||||
|
||||
fg <- function( sprdname=.Active )
|
||||
# sprdname = character name, possibly subscripted
|
||||
{
|
||||
if (is.na(match(sprdname, names(macro(.Registry))))) {
|
||||
macro(.Registry)[sprdname] <- sprdname
|
||||
assign(".Registry", .Registry, where=1 )
|
||||
}
|
||||
assign(".Active.buffer", sprdname, frame=0 )
|
||||
assign(".Active", find.names(sprdname), frame=0 )
|
||||
assign("x", eval(parse(text=.Active)), where=1 )
|
||||
assign("x.buffer", where=1,
|
||||
if (.Active.buffer==.Active) x
|
||||
else as.two.way.array(eval(parse(text=.Active.buffer))))
|
||||
invisible(sprdname)
|
||||
}
|
||||
|
||||
control.emacs <- function(x)
|
||||
{
|
||||
#this is a fake function
|
||||
#emacs does the work
|
||||
|
||||
# control.emacs never gets called when emacs is in control.
|
||||
# RET in spread window puts old command in minibuffer:
|
||||
# emacs sends
|
||||
# emacs.cell('spreadname', e.r, e.c, result.type)
|
||||
# emacs reads the file written by the above and
|
||||
# asks the user to revise it in the minibuffer.
|
||||
# RET in minibuffer puts revised command in S buffer,
|
||||
# and causes the revised command to be executed, updating the spreadsheet.
|
||||
# emacs issues
|
||||
# invisible(assign(.Active, x))
|
||||
# to place the object in x into the object named in .Active
|
||||
# emacs issues
|
||||
# print.find.emacs('spreadname', update.Registry=F)
|
||||
# to update all buffers showing views of the object named in .Active
|
||||
# When S gets control back, the command has been executed and the
|
||||
# spreadsheet has been updated
|
||||
}
|
||||
|
||||
#emacs usage
|
||||
#load-file S-spread.el
|
||||
#In the *S* buffer, type ^Cr to place a spread.frame or 2-way or 3-way array
|
||||
# into a spread.frame buffer.
|
||||
#In the spread.frame buffer, type RET to update a cell.
|
||||
#In the minibuffer, revise the cell and type RET to update the object and
|
||||
# the display.
|
||||
#If there is a timing problem and the display is not updated,
|
||||
# then type ^Cv in the spread buffer.
|
||||
|
||||
|
||||
|
||||
find.sprds <- function(sprdname, reg.names=names(macro(.Registry)))
|
||||
{
|
||||
reg.names[find.names(reg.names) == find.names(sprdname)]
|
||||
}
|
||||
|
||||
find.names <- function(reg.names)
|
||||
{
|
||||
prn <- parse(text=reg.names)
|
||||
for (i in 1:length(prn))
|
||||
if (mode(prn[[i]]) != "name") reg.names[i] <- prn[[i]][[2]]
|
||||
reg.names
|
||||
}
|
||||
|
||||
|
||||
print.sprds.emacs <- function(sprdname)
|
||||
{
|
||||
fssn <- find.sprds(sprdname)
|
||||
fssn2 <- fssn
|
||||
for(i in fssn2) {
|
||||
fg(i)
|
||||
print.update.emacs(x.buffer)
|
||||
}
|
||||
cat(paste(fssn, collapse="\n"), "\n", sep="", file=.spread.command.file)
|
||||
invisible(fg(sprdname))
|
||||
}
|
||||
|
||||
print.update.emacs.3d <- function(object)
|
||||
{
|
||||
object.name <- as.character(substitute(object))
|
||||
dobject <- dim(object)
|
||||
if (length(dobject) != 3) stop("3-way array required")
|
||||
fg(object.name)
|
||||
|
||||
n3 <- dimnames(object)[[3]]
|
||||
if (is.null(n3)) n3 <- seq(length=dobject[3])
|
||||
else n3 <- paste("\"", n3, "\"", sep="")
|
||||
for (i in n3) {
|
||||
fg(paste( object.name, "[,,", i, "]", sep="" ))
|
||||
print.update.emacs(x.buffer)
|
||||
}
|
||||
invisible(object)
|
||||
}
|
||||
|
||||
emacs.start <- function(spread.directory)
|
||||
{
|
||||
assign('.spread.directory', spread.directory, frame=0)
|
||||
if (!exists('.Registry', 1))
|
||||
assign(".Registry", where=1, as.spread(matrix(".Registry")))
|
||||
assign(".spread.command.file", frame=0,
|
||||
paste(spread.directory, "*command*", sep="/"))
|
||||
fg(".Registry")
|
||||
print.update.emacs(.Registry)
|
||||
invisible(".Registry")
|
||||
}
|
||||
|
||||
|
||||
print.find.emacs <- function(spread=.Active, update.Registry=T)
|
||||
{
|
||||
fg(spread)
|
||||
if (update.Registry) {
|
||||
fg(".Registry")
|
||||
print.update.emacs(.Registry)
|
||||
fg(spread)
|
||||
}
|
||||
print.sprds.emacs(spread)
|
||||
invisible(spread)
|
||||
}
|
||||
|
||||
|
||||
emacs.cell <- function(spread, e.r, e.c, result.type)
|
||||
{
|
||||
fg(spread)
|
||||
cell.rc <- cell.rc.emacs(x.buffer, e.r, e.c)
|
||||
.Options$width <- 1000
|
||||
if (result.type==1 && cell.rc[1] <= nrow(x.buffer)) {
|
||||
cell.rc <- cell.sub.emacs(x, cell.rc)
|
||||
cell.expr <- expr.rc(x, cell.rc)
|
||||
}
|
||||
else
|
||||
cell.expr <- emacs.expr(x, cell.rc, result.type=result.type)
|
||||
cat(cell.expr, '\n', sep='', file=.spread.command.file)
|
||||
}
|
||||
|
||||
cell.sub.emacs <- function(x, i, j=i[2])
|
||||
{
|
||||
# i and j are integer scalars
|
||||
|
||||
if (missing(j)) {j <- i[2] ; i <- i[1]}
|
||||
if (i==0 && j==0) stop("non-zero row or column required")
|
||||
|
||||
if ((length(dim(x)) == 2)) {
|
||||
acpab <- c("","")
|
||||
positions <- 1:2
|
||||
}
|
||||
else if (.Active == .Active.buffer)
|
||||
stop("Must use rectangular slice, not 3d buffer")
|
||||
else {
|
||||
pab <- parse(text=.Active.buffer)
|
||||
acpab <- as.character( pab[[1]][-(1:2)] )
|
||||
positions <- (1:length(acpab))[sapply(acpab, nchar) == 0]
|
||||
}
|
||||
|
||||
di <- index.value(dimnames(x)[[positions[1]]], i)
|
||||
dj <- index.value(dimnames(x)[[positions[2]]], j)
|
||||
|
||||
acpab[positions[1]] <- di
|
||||
acpab[positions[2]] <- dj
|
||||
|
||||
acpab
|
||||
}
|
49
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-grd.s
Normal file
49
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-grd.s
Normal file
@@ -0,0 +1,49 @@
|
||||
as.grade <- function(x)
|
||||
{
|
||||
if (inherits(x,"grade")) return(x)
|
||||
if (match("sum",dimnames(x)[[2]],0) == 0) {
|
||||
dx <- dim(x)
|
||||
dnx <- dimnames(x)
|
||||
if (length(dim(x)) == 2) {
|
||||
if (length(dnx) != 2) dimnames(x) <- list(NULL, 1:dx[2])
|
||||
tmp <- cbind(x,sum=0)
|
||||
}
|
||||
if (length(dim(x)) == 3) {
|
||||
dimnames(x) <- NULL
|
||||
tmp <- aperm(x,c(1,3,2))
|
||||
dim(tmp) <- c(dim(tmp)[1]*dim(tmp)[3], dim(tmp)[2])
|
||||
tmp <- cbind(tmp, sum=0)
|
||||
dim(tmp) <- (dx + c(0,1,0))[c(1,3,2)]
|
||||
tmp <- aperm(tmp,c(1,3,2))
|
||||
if (length(dnx) != 3) dnx <- list(NULL, 1:dx[2], NULL)
|
||||
dnx[[2]] <- c(dnx[[2]], "sum")
|
||||
dimnames(tmp) <- dnx
|
||||
}
|
||||
if (length(dim(x)) > 3) stop("grade requires 2d or 3d")
|
||||
}
|
||||
x <- as.spread(tmp)
|
||||
sum.col <- match("sum",dimnames(x)[[2]],0)
|
||||
tmp.expr <- paste(
|
||||
"x[,",
|
||||
sum.col,
|
||||
if (length(dim(x))==3) ",",
|
||||
"] <- apply(x[,",
|
||||
-sum.col,
|
||||
if (length(dim(x))==3) ",",
|
||||
"],",
|
||||
deparse(if (length(dim(x))==3) c(1,3) else 1),
|
||||
",sum)"
|
||||
)
|
||||
after(x)["sum"] <- parse(text=tmp.expr)
|
||||
class(x) <- c("grade", class(x))
|
||||
update.spread(x)
|
||||
}
|
||||
|
||||
expr.rc.grade <- function(x, acpab)
|
||||
{
|
||||
if (sapply(acpab,nchar)[[2]] == 0) {
|
||||
j <- -match("sum", dimnames(x)[[2]], 0)
|
||||
acpab[2] <- j
|
||||
}
|
||||
expr.rc.default(x,acpab)
|
||||
}
|
336
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-int.el
Normal file
336
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-int.el
Normal file
@@ -0,0 +1,336 @@
|
||||
;; spreadsheet in S
|
||||
;; Richard M. Heiberger
|
||||
;; 1995
|
||||
|
||||
;; Load this file from the dired window in which .Data exists.
|
||||
;; This file does not work with S-mode. Use S-spread.el for S-mode.
|
||||
|
||||
|
||||
(set-variable 'buffers-menu-max-size nil)
|
||||
|
||||
|
||||
(defvar spread-directory (concat "/tmp/" (make-temp-name "spr"))
|
||||
"Directory in which to store ascii spreadsheet displays.")
|
||||
|
||||
(defvar spread-command-file (concat spread-directory "/*command*")
|
||||
"File through which S will communicate with emacs.")
|
||||
|
||||
(defvar spread-directory-p nil
|
||||
"predicate value non-nil when directory has been defined.")
|
||||
|
||||
(defun print-find-emacs nil "display spread.frame from minibuffer" (interactive)
|
||||
(spread-print-find (read-string "spread.frame: ") t))
|
||||
|
||||
(define-key global-map "\C-cr" 'print-find-emacs)
|
||||
|
||||
|
||||
|
||||
(defun emacs-rc nil "" (interactive)
|
||||
(emacs-cell "1")
|
||||
)
|
||||
|
||||
(defun emacs-macro nil "" (interactive)
|
||||
(emacs-cell "2")
|
||||
)
|
||||
|
||||
(defun emacs-macro-control-text nil "" (interactive)
|
||||
(emacs-cell "4")
|
||||
)
|
||||
|
||||
(defun emacs-macro-print-text nil "" (interactive)
|
||||
(emacs-cell "5")
|
||||
)
|
||||
|
||||
(defun emacs-cell (result-type) "" (interactive)
|
||||
(setq spread-name (buffer-name))
|
||||
(setq r (count-lines 1 (point)))
|
||||
(setq c (current-column))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert
|
||||
(format "emacs.cell('%s', %s, %s, %s)"
|
||||
spread-name r c result-type
|
||||
)
|
||||
)
|
||||
(save-excursion
|
||||
(set-buffer "*command*")
|
||||
(revert-t-t)
|
||||
(goto-char (point-min))
|
||||
(setq beg (point)) (end-of-line)
|
||||
(if (equal result-type "4")
|
||||
(progn
|
||||
(setq command (buffer-substring beg (point)))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert command)
|
||||
)
|
||||
(setq command (read-string "> " (buffer-substring beg (point))))
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert command)
|
||||
(spread-insert "invisible(assign(.Active, x))")
|
||||
(spread-print-find spread-name nil)
|
||||
(goto-line r)(forward-char c)
|
||||
))
|
||||
)
|
||||
|
||||
(defun spread-insert (spread-command) "" (interactive)
|
||||
(goto-char (point-max))
|
||||
(insert spread-command)
|
||||
(comint-send-input)
|
||||
(accept-process-output spread-process)
|
||||
)
|
||||
|
||||
(defun revert-t-t nil "revert-buffer with no questions asked"
|
||||
(interactive)
|
||||
(revert-buffer t t)
|
||||
)
|
||||
|
||||
(defun revert-t-t-read-only nil "revert-buffer, no questions, read-only"
|
||||
(interactive)
|
||||
(revert-buffer t t)
|
||||
(setq buffer-read-only t)
|
||||
)
|
||||
|
||||
(define-key global-map "\C-cv" 'revert-t-t)
|
||||
|
||||
(defvar spread-mode-map nil "Keymap for Spread mode.")
|
||||
(if spread-mode-map
|
||||
nil
|
||||
(setq spread-mode-map (make-sparse-keymap))
|
||||
(define-key spread-mode-map "\C-cv" 'revert-t-t-read-only)
|
||||
(define-key spread-mode-map "\C-m" 'emacs-rc)
|
||||
(define-key spread-mode-map "\C-cc" 'emacs-macro)
|
||||
(define-key spread-mode-map "\C-cs" 'emacs-macro-control-text)
|
||||
(define-key spread-mode-map "\C-cp" 'emacs-macro-print-text)
|
||||
(define-key spread-mode-map "f" 'emacs-print-find-emacs)
|
||||
|
||||
(define-key spread-mode-map [mouse-2] 'spread-mouse-print-find-emacs)
|
||||
(define-key spread-mode-map [mouse-3] 'spread-mouse-rc)
|
||||
;; (define-key spread-mode-map [double-mouse-1] 'spread-mouse-rc) ;doesn't work
|
||||
|
||||
(define-key spread-mode-map [menu-bar spread]
|
||||
(cons "Spread" (make-sparse-keymap "Spread")))
|
||||
; (define-key spread-mode-map [menu-bar spread spread-macro]
|
||||
; '("macro" . spread-macro))
|
||||
(define-key spread-mode-map [menu-bar spread spread-before]
|
||||
'("before" . spread-before))
|
||||
(define-key spread-mode-map [menu-bar spread spread-after]
|
||||
'("after" . spread-after))
|
||||
(define-key spread-mode-map [menu-bar spread spread-macro]
|
||||
(cons "Macro" (make-sparse-keymap "sprdtwo")))
|
||||
(define-key spread-mode-map [menu-bar spread spread-macro display]
|
||||
'("after" . spread-display))
|
||||
; (define-key spread-mode-map [mouse-2] 'emacs-menu-print-find-ww)
|
||||
)
|
||||
|
||||
(defun spread-mouse-rc (event) "move point then enter"
|
||||
(interactive "e")
|
||||
(mouse-set-point event)
|
||||
(emacs-rc)
|
||||
)
|
||||
|
||||
(defun spread-mouse-print-find-emacs (event) "move point then find file"
|
||||
(interactive "e")
|
||||
(mouse-set-point event)
|
||||
(emacs-print-find-emacs)
|
||||
)
|
||||
|
||||
(defun spread-mode () "Major mode for spreadsheets.\\{spread-mode-map}"
|
||||
(interactive)
|
||||
(kill-all-local-variables)
|
||||
(make-local-variable 'beg)
|
||||
(make-local-variable 'command)
|
||||
(use-local-map spread-mode-map)
|
||||
(setq mode-name "Spread")
|
||||
(setq major-mode 'spread-mode)
|
||||
(if (equal (buffer-name) ".Registry") (spread-highlight-macro))
|
||||
(setq buffer-read-only t)
|
||||
)
|
||||
|
||||
|
||||
;; from dired.el L547
|
||||
; (put-text-property (point)
|
||||
; (save-excursion
|
||||
; (dired-move-to-end-of-filename)
|
||||
; (point))
|
||||
; 'mouse-face 'highlight)
|
||||
;
|
||||
;; (put-text-property (point) (mark) 'mouse-face 'highlight)
|
||||
|
||||
|
||||
(defun spread-highlight-macro nil
|
||||
"highlight spread.frame names for mouse access"
|
||||
(interactive)
|
||||
(save-excursion
|
||||
(goto-char (point-min))
|
||||
(search-forward "**macro**")(forward-char)
|
||||
|
||||
(toggle-read-only -1)
|
||||
(while (progn
|
||||
(setq beg (point))(end-of-line)
|
||||
(not (= beg (point)))
|
||||
)
|
||||
(put-text-property beg (1-(point)) 'mouse-face 'highlight)
|
||||
(forward-char)
|
||||
)
|
||||
(toggle-read-only 1)
|
||||
)
|
||||
(save-buffer)
|
||||
)
|
||||
|
||||
(defun emacs-print-find-emacs nil "" (interactive)
|
||||
(beginning-of-line)
|
||||
(setq beg (point)) (end-of-line) (backward-char)
|
||||
(setq spread-name (buffer-substring beg (point)))
|
||||
(spread-print-find spread-name nil)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
(defun find-spread-frame-directory nil
|
||||
"Locate directory in which spread.frame functions are stored."
|
||||
(list-command-history)
|
||||
(set-buffer "*Command History*")
|
||||
(goto-char (point-min))
|
||||
(search-forward "(load-file ")
|
||||
(goto-char (1+ (match-end 0)))(setq beg (point))
|
||||
(end-of-line)(search-backward "/")
|
||||
(goto-char (match-end 0))
|
||||
(setq spread-frame-directory
|
||||
(expand-file-name (buffer-substring beg (point))))
|
||||
)
|
||||
|
||||
(defun inferior-spread-mode ()
|
||||
"Major mode for running spread.frames under S/Splus."
|
||||
(comint-run S-program)
|
||||
(setq comint-prompt-regexp shell-prompt-pattern)
|
||||
(setq major-mode 'inferior-spread-mode)
|
||||
(setq mode-name "Inferior Spread")
|
||||
(setq mode-line-process '(":%s"))
|
||||
(setq spread-process (get-buffer-process (current-buffer)))
|
||||
(set-process-filter spread-process 'comint-output-filter)
|
||||
(set-variable 'comint-output-filter-functions
|
||||
'(spread-output-filter
|
||||
comint-postoutput-scroll-to-bottom)
|
||||
)
|
||||
(set-variable 'comint-scroll-to-bottom-on-output "this")
|
||||
(set-variable 'comint-scroll-show-maximum-output t)
|
||||
(if (not(file-writable-p ".Data/.Audit"))
|
||||
(accept-process-output spread-process))
|
||||
(accept-process-output spread-process)
|
||||
)
|
||||
|
||||
|
||||
(defun spread-output-filter (str)
|
||||
"detect errors in S output"
|
||||
(if (or
|
||||
(string-match "Dumped" str)
|
||||
(string-match "Error" str)
|
||||
)
|
||||
(progn
|
||||
(switch-to-buffer-other-window S-buffer)
|
||||
(comint-show-maximum-output)
|
||||
(set-variable 'quit-flag t); beeps and writes "quit" in the message area
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
|
||||
|
||||
;(put 'spread-region 'menu-enable 'mark-active)
|
||||
;(put 'spread-validate-region 'menu-enable 'mark-active)
|
||||
;(put 'spread-print 'menu-enable '(stringp spread-print-file))
|
||||
;(put 'spread-alt-print 'menu-enable '(stringp spread-print-file))
|
||||
;(put 'spread-view 'menu-enable '(stringp spread-print-file))
|
||||
;(put 'spread-recenter-output-buffer 'menu-enable '(get-buffer "*spread-shell*"))
|
||||
;(put 'spread-kill-job 'menu-enable '(spread-shell-running))
|
||||
|
||||
|
||||
|
||||
(defun emacs-menu-print-find (spread-name) "" (interactive)
|
||||
(spread-print-find spread-name nil)
|
||||
)
|
||||
|
||||
(defun spread-print-find (spread-name update-Registry)
|
||||
"Place SPREAD-NAME in foreground of S-buffer (*S* or *Splus*),
|
||||
update .Registry and revert buffer when UPDATE-REGISTRY is t,
|
||||
print all views of spread.frame associated with SPREAD-NAME in .Registry
|
||||
to /tmp/spr***** directory, and find or revert all views into emacs buffers."
|
||||
(interactive)
|
||||
(set-buffer S-buffer)
|
||||
(spread-insert
|
||||
(format "print.find.emacs('%s', update.Registry=%s)"
|
||||
spread-name (if update-Registry "T" "F")))
|
||||
(if update-Registry
|
||||
(save-excursion (spread-find-file ".Registry")))
|
||||
(spread-print-sprds)
|
||||
(switch-to-buffer spread-name)
|
||||
)
|
||||
|
||||
(defun spread-print-sprds () "Display in buffers all views of spread.frame"
|
||||
(interactive)
|
||||
(save-excursion
|
||||
(set-buffer "*command*")
|
||||
(revert-t-t)
|
||||
(goto-char (point-min))
|
||||
|
||||
(while (< (point) (point-max))
|
||||
(set-buffer "*command*")
|
||||
(setq beg (point)) (end-of-line)
|
||||
(setq spread-name-i (buffer-substring beg (point)))
|
||||
(save-excursion (spread-find-file spread-name-i))
|
||||
(forward-line)))
|
||||
)
|
||||
|
||||
(defun spread-find-file (spread-name) "Display one view of spread.frame"
|
||||
(interactive)
|
||||
(switch-to-buffer spread-name)
|
||||
(if (buffer-file-name)
|
||||
(revert-t-t-read-only)
|
||||
(kill-buffer spread-name)
|
||||
(find-file (concat spread-directory "/" spread-name))
|
||||
)
|
||||
(spread-mode)
|
||||
)
|
||||
|
||||
(define-key spread-mode-map [menu-bar spread ww]
|
||||
'("ww" . emacs-menu-print-find-ww))
|
||||
|
||||
(defun emacs-menu-print-find-ww () "" (interactive)
|
||||
(emacs-menu-print-find "ww"))
|
||||
|
||||
(define-key spread-mode-map [menu-bar spread ww2]
|
||||
'("ww2" . "\e\e (emacs-menu-print-find \"ww\")"))
|
||||
|
||||
(define-key spread-mode-map [menu-bar spread ww3]
|
||||
'("ww3" . "\M-x eval-expression\C-m (emacs-menu-print-find \"ww\")"))
|
||||
|
||||
|
||||
|
||||
|
||||
(defun spread-start () "load emacs spread.frame handler"
|
||||
(if (not (equal major-mode 'dired-mode)) (set-variable 'quit-flag t))
|
||||
(setq spread-home-directory (dired-current-directory))
|
||||
(find-spread-frame-directory)
|
||||
(kill-buffer "*Command History*")
|
||||
(if (not spread-directory-p)
|
||||
(progn (make-directory spread-directory)
|
||||
(setq spread-directory-p t)))
|
||||
(setq S-program (read-string "Splus or S? " "Splus"))
|
||||
(setq S-buffer (concat "*" S-program "*"))
|
||||
(if (not (get-buffer S-buffer))
|
||||
(get-buffer-create S-buffer))
|
||||
(if (get-buffer-process S-buffer) (set-variable 'quit-flag t))
|
||||
(set-buffer S-buffer)
|
||||
(cd spread-home-directory)
|
||||
(inferior-spread-mode)
|
||||
(spread-insert
|
||||
(format "attach('%s.Data')" spread-frame-directory))
|
||||
(spread-insert
|
||||
(format "emacs.start('%s')" spread-directory))
|
||||
(find-file spread-command-file)
|
||||
(spread-find-file ".Registry")
|
||||
)
|
||||
|
||||
;; start it up
|
||||
(spread-start)
|
BIN
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-int.elc
Normal file
BIN
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-int.elc
Normal file
Binary file not shown.
329
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-spr.s
Normal file
329
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-spr.s
Normal file
@@ -0,0 +1,329 @@
|
||||
#-*-Fundamental-*-
|
||||
|
||||
|
||||
# Spreadsheet written in S
|
||||
|
||||
# The spreadsheet may be called anything.
|
||||
# References to cells in the spreadsheet must be called "x".
|
||||
|
||||
# Updating is in column order.
|
||||
|
||||
# Version 3 classes and methods technology.
|
||||
|
||||
|
||||
as.spread <- function(x)
|
||||
{
|
||||
if (is.spread(x)) return(x)
|
||||
x <- as.array(x)
|
||||
attr(x,"expr") <- as.expr(x, length=0)
|
||||
attr(x,"macro") <- as.expr(x, length=0)
|
||||
attr(x,"before") <- as.expr(x, length=0)
|
||||
attr(x,"after") <- as.expr(x, length=0)
|
||||
class(x) <- c("spread", class(x))
|
||||
x
|
||||
}
|
||||
|
||||
is.spread <- function(x)
|
||||
inherits(x,"spread")
|
||||
|
||||
|
||||
print.spread <- function(x, ..., quote=F)
|
||||
{
|
||||
if (inherits(x, "data.frame")) print.data.frame(x)
|
||||
else {
|
||||
class(x) <- class(x)[-match("spread",class(x))]
|
||||
print.array(x, ..., quote=quote)
|
||||
}
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
|
||||
|
||||
"[.spread"<-
|
||||
function(x, ..., drop = F)
|
||||
{
|
||||
# Note: We do not retain the spread class!
|
||||
# If we did, the subscripts on the expr() and macros() would be wrong
|
||||
#
|
||||
NextMethod("[", drop=drop)
|
||||
}
|
||||
|
||||
|
||||
"[.expr" <- function(x, ... , drop=F)
|
||||
{
|
||||
# Note: We do retain the expr class.
|
||||
# The primary use is for printing, so we want the original subscripting.
|
||||
|
||||
z <- NextMethod("[", drop=drop)
|
||||
class(z) <- class(x)
|
||||
z
|
||||
}
|
||||
|
||||
|
||||
update.spread <- function(object, ..., force=F)
|
||||
{
|
||||
if (force) object <- eval.spread(object, NULL, force=force)
|
||||
if (length(before(object)))
|
||||
object <- eval.spread(object, before(object))
|
||||
if (length(expr(object)))
|
||||
object <- eval.spread(object, force=force)
|
||||
if (length(after(object)))
|
||||
object <- eval.spread(object, after(object))
|
||||
object
|
||||
}
|
||||
|
||||
eval.spread <- function(object, e, force=F)
|
||||
{
|
||||
x <- object
|
||||
class(x) <- class(x)[-match("spread",class(x))]
|
||||
if (force) {
|
||||
.Options$warn <- -1
|
||||
tmp <- as.numeric(as.matrix(x))
|
||||
if (!any(is.na(tmp))) x <- tmp
|
||||
}
|
||||
if (missing(e)) {
|
||||
if (inherits(x,"data.frame")) {
|
||||
e <- expr(object)
|
||||
if (force)
|
||||
for (j in 1:ncol(x)) for (i in 1:nrow(x))
|
||||
x[[i,j]] <- eval(e[i,j])
|
||||
else
|
||||
for (j in 1:ncol(x)) for (i in 1:nrow(x)) {
|
||||
eij <- e[i,j]
|
||||
if(is.language(eij)) x[[i,j]] <- eval(eij)
|
||||
}
|
||||
}
|
||||
else {
|
||||
i <- 0
|
||||
if (force)
|
||||
for (ei in expr(object))
|
||||
{i <- i+1; x[i] <- eval(ei)}
|
||||
else
|
||||
for (ei in expr(object))
|
||||
{i <- i+1; if(is.language(ei)) x[i] <- eval(ei)}
|
||||
}
|
||||
}
|
||||
else eval(e)
|
||||
class(x) <- class(object)
|
||||
x
|
||||
}
|
||||
|
||||
#usage: x <- macro.eval(x, i)
|
||||
macro.eval <- function(object, i)
|
||||
eval.spread(object, macro(x)[i])
|
||||
|
||||
|
||||
"[[<-.spread" <- function(...) do.call("[<-.spread", list(...))
|
||||
|
||||
"[<-.spread" <- function(object, ..., value)
|
||||
{
|
||||
x <- object
|
||||
expr(x) <- expression()
|
||||
class(x) <- NULL
|
||||
e <- expr(object)
|
||||
l.e <- length(e)
|
||||
i.a.v <- is.atomic(substitute(value))
|
||||
n.cells <- prod(dim(x[..., drop=F]))
|
||||
|
||||
if (l.e == 0) {
|
||||
if (n.cells != 1 || i.a.v )
|
||||
x[...] <- eval(substitute(value))
|
||||
else {
|
||||
e <- as.expr(object)
|
||||
l.e <- length(e)
|
||||
}
|
||||
}
|
||||
if (l.e != 0) {
|
||||
if (n.cells != 1) {
|
||||
e.s.v <- eval(substitute(value, sys.parent()))
|
||||
x[...] <- e.s.v
|
||||
e[...] <- e.s.v
|
||||
}
|
||||
else {
|
||||
e[[...]] <- substitute(value)
|
||||
x[[...]] <- eval(e[[...]])
|
||||
}
|
||||
}
|
||||
attributes(x) <- attributes(object)
|
||||
class(x) <- class(object)
|
||||
expr(x) <- e
|
||||
update.spread(x)
|
||||
}
|
||||
|
||||
|
||||
print.expr <- function(e, ..., replace.string=F) {
|
||||
replace <- as.logical(replace.string)
|
||||
if (length(e) == 0) {
|
||||
if (replace) cat(replace.string, "<- ")
|
||||
print(expression())
|
||||
}
|
||||
else if (is.null(dim(e))) {
|
||||
ne <- names(e)
|
||||
for (i in 1:length(e)) {
|
||||
nei <- index.value(ne, i)
|
||||
if (replace) cat(replace.string)
|
||||
cat(paste("[", nei, "] ", sep=""))
|
||||
if (replace) cat("<- expression(")
|
||||
cat(e[i])
|
||||
if (replace) cat(")")
|
||||
cat("\n")
|
||||
}
|
||||
}
|
||||
else {
|
||||
dn <- dimnames(e)
|
||||
if (is.null(dn)) dn <- list()
|
||||
for (i in 1:length(dim(e))) {
|
||||
if (is.null(dn[[i]])) dn[[i]] <- 1:dim(e)[i]
|
||||
}
|
||||
dnn <- outer(dn[[1]], dn[[2]], paste, sep=",")
|
||||
if (length(dn) > 2)
|
||||
for (i in 3:length(dn))
|
||||
dnn <- outer(dnn, dn[[i]], paste, sep=",")
|
||||
for (i in seq(length=length(e))) {
|
||||
if (replace) cat("x")
|
||||
cat(paste("[", dnn[i], "] ", sep=""))
|
||||
if (replace) cat("<-")
|
||||
cat(paste(" ", e[i], "\n", sep=""))
|
||||
}
|
||||
}
|
||||
invisible(e)
|
||||
}
|
||||
|
||||
as.expr <- function(x, ...) UseMethod("as.expr")
|
||||
|
||||
as.expr.default <- function(x, length.x=prod(dim(x))) {
|
||||
e <- vector(mode="expression", length=length.x)
|
||||
x <- unclass(x)
|
||||
if (length.x > 0) {
|
||||
e <- array(e, dim(x), dimnames(x))
|
||||
e[] <- x[]
|
||||
# for (i in 1:length(e)) e[i] <- x[i]
|
||||
}
|
||||
class(e) <- "expr"
|
||||
e
|
||||
}
|
||||
|
||||
as.expr.data.frame <- function(x, length.x=prod(dim(x))) {
|
||||
e <- vector(mode="expression", length=length.x)
|
||||
if (length.x > 0) {
|
||||
e <- array(e, dim(x), dimnames(x))
|
||||
u.x <- unclass(x)
|
||||
for (j in 1:ncol(x)) {
|
||||
uxj <- as.matrix(u.x[[j]])
|
||||
for (i in 1:nrow(x))
|
||||
e[i,j] <- uxj[i,1]
|
||||
}
|
||||
}
|
||||
class(e) <- "expr"
|
||||
e
|
||||
}
|
||||
|
||||
|
||||
expr <- function(x)
|
||||
attr(x,"expr")
|
||||
|
||||
# "expr<-" is used only when value is a matrix the size of x, or to update
|
||||
# a subscripted piece of x. It is not a user function.
|
||||
# Currently used only in "[<-.spread".
|
||||
"expr<-" <- function(x, value)
|
||||
{
|
||||
attr(x,"expr") <- value
|
||||
x
|
||||
}
|
||||
|
||||
"before<-" <- function(x, value)
|
||||
{
|
||||
attr(x,"before") <- value
|
||||
class(attr(x,"before")) <- "expr"
|
||||
x
|
||||
}
|
||||
|
||||
"macro<-" <- function(x, value)
|
||||
{
|
||||
attr(x,"macro") <- value
|
||||
class(attr(x,"macro")) <- "expr"
|
||||
x
|
||||
}
|
||||
|
||||
"after<-" <- function(x, value)
|
||||
{
|
||||
attr(x,"after") <- value
|
||||
class(attr(x,"after")) <- "expr"
|
||||
x
|
||||
}
|
||||
|
||||
before <- function(x)
|
||||
attr(x,"before")
|
||||
|
||||
|
||||
macro <- function(x)
|
||||
attr(x,"macro")
|
||||
|
||||
|
||||
after <- function(x)
|
||||
attr(x,"after")
|
||||
|
||||
|
||||
expr.rc <- function(x, ...) UseMethod("expr.rc")
|
||||
|
||||
expr.rc.default <- function(x, acpab)
|
||||
{
|
||||
subs <- paste("[", paste(acpab, collapse=","), "]")
|
||||
|
||||
if (length(expr(x))==0) {
|
||||
x.expr <- paste("x.value(x",subs,")",sep="")
|
||||
value <- eval(parse(text=x.expr))
|
||||
}
|
||||
else {
|
||||
e.expr <- paste("expr.value(expr(x)", subs, ", x", subs, ")")
|
||||
value <- eval(parse(text=e.expr))
|
||||
}
|
||||
|
||||
paste("x", subs, " <- ", value, sep="")
|
||||
}
|
||||
|
||||
|
||||
x.value <- function(x) {
|
||||
value <-
|
||||
if (length(x)==1)
|
||||
as.vector(as.matrix(x[[1]]))
|
||||
else if (inherits(x,"data.frame"))
|
||||
lapply(x, function(x) as.vector(as.matrix(x)))
|
||||
else
|
||||
as.vector(x)
|
||||
deparse(value)
|
||||
}
|
||||
|
||||
expr.value <- function(e, x) {
|
||||
if (inherits(x,"data.frame") &&
|
||||
(dim(e)[2]>1 || inherits(x[[1]],"factor")))
|
||||
value <- deparse(lapply(e, function(x) as.vector(as.matrix(x))))
|
||||
else {
|
||||
value <- paste(e, collapse=",")
|
||||
if (length(e) > 1) value <- paste("c(", value, ")", sep="")
|
||||
}
|
||||
value
|
||||
}
|
||||
|
||||
|
||||
index.value <- function(dn, i, deparse.result=T) {
|
||||
if (i==0) {i <- 0; mode(i) <- "missing"}
|
||||
if (is.numeric(i) && i>0 && length(dn)) i <- dn[i]
|
||||
if (deparse.result) deparse(as.vector(i))
|
||||
else as.vector(i)
|
||||
}
|
||||
|
||||
as.numeric.spread <- function(x)
|
||||
{
|
||||
.Options$warn <- -1
|
||||
tmp <- as.numeric(unclass(x))
|
||||
tmp <- ifelse(is.na(tmp), 0, tmp)
|
||||
attributes(tmp) <- attributes(x)
|
||||
tmp
|
||||
}
|
||||
|
||||
all.numeric <- function(x) {
|
||||
.Options$warn <- -1
|
||||
!any(is.na(as.numeric(x)))
|
||||
}
|
||||
|
114
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-txt.s
Normal file
114
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd-txt.s
Normal file
@@ -0,0 +1,114 @@
|
||||
# prspread is based on prmatrix
|
||||
prspread <-
|
||||
function(x, rowlab = character(0), collab = character(0), quote = T, right = F,
|
||||
spread.name=deparse(match.call()[["x"]]) )
|
||||
{
|
||||
d <- dim(x)
|
||||
dnames <- dimnames(x)
|
||||
if(is.null(dnames))
|
||||
dnames <- list(rowlab, collab)
|
||||
else {
|
||||
if(!missing(rowlab))
|
||||
dnames[[1]] <- as.character(rowlab)
|
||||
if(!missing(collab))
|
||||
dnames[[2]] <- as.character(collab)
|
||||
}
|
||||
if(length(dnames[[1]]) == 0)
|
||||
dnames[[1]] <- paste("[", 1:d[1], ",]", sep = "")
|
||||
else if(length(dnames[[1]]) != d[1])
|
||||
stop("rowlab is wrong length")
|
||||
if(length(dnames[[2]]) == 0)
|
||||
dnames[[2]] <- paste("[,", 1:d[2], "]", sep = "")
|
||||
else if(length(dnames[[2]]) != d[2])
|
||||
stop("collab is wrong length")
|
||||
cbind(c(spread.name,dnames[[1]]), rbind(dnames[[2]], as.matrix(x)))
|
||||
}
|
||||
|
||||
|
||||
|
||||
row.ch <- function(x, d=dim(x))
|
||||
array(1:d[1], d, dimnames(x))
|
||||
|
||||
col.ch <- function(x, d=dim(x))
|
||||
array(rep.int(1:d[2], rep.int(d[1], d[2])), d, dimnames(x))
|
||||
|
||||
|
||||
print.text <- function(x, screen.n, cex=1,
|
||||
spread.name=deparse(match.call()[["x"]]), clear=T, ...)
|
||||
{
|
||||
x.pr <- prspread(x, spread.name=spread.name)
|
||||
if (!missing(screen.n)) screen(screen.n)
|
||||
usr <- c(0, ncol(x.pr), 0, nrow(x.pr)) - .5
|
||||
par(usr=usr)
|
||||
par(plt=c(0,1,0,1))
|
||||
if (clear)
|
||||
polygon(usr[c(1,2,2,1)],usr[c(3,3,4,4)], den=-1,col=0,xaxt="s",yaxt="s")
|
||||
text(x=as.vector(col.ch(x.pr)-1),
|
||||
y=as.vector(nrow(x.pr)-row.ch(x.pr)), x.pr, cex=cex, ...)
|
||||
box()
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
text.update.spread <- function(xij, row.i, col.j, screen.n, cex=1, x)
|
||||
{
|
||||
if (!missing(screen.n)) {screen(screen.n, new=F); par(plt=c(0,1,0,1))}
|
||||
y <- nrow(x)-row.i
|
||||
clear.text(x=col.j, y=y)
|
||||
text(x=col.j, y=y, xij, cex=cex)
|
||||
box()
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
|
||||
cell.rc.text <- function(nrow.x, n=1, type="n")
|
||||
{
|
||||
xy <- locator(n, type)
|
||||
c(row=nrow.x-round(xy$y), col=round(xy$x))
|
||||
}
|
||||
|
||||
clear.text <- function(x,y)
|
||||
polygon(x-.5+c(0,1,1,0), y-.5+c(0,0,1,1), den=-1, col=0, border=F,
|
||||
xaxt="s", yaxt="s")
|
||||
|
||||
|
||||
print.update.text <- function(x, ..., x.old, screen.n, cex=1,
|
||||
spread.name=deparse(match.call()[["x"]]))
|
||||
{
|
||||
if(missing(x.old)) return(invisible(print.text(x, screen=screen.n,
|
||||
cex=cex, spread.name=spread.name)))
|
||||
if (!missing(screen.n)) {screen(screen.n, new=F); par(plt=c(0,1,0,1))}
|
||||
diff.x <- as.vector(x != x.old)
|
||||
xx <- col(x)[diff.x]
|
||||
yy <- nrow(x)-row(x)[diff.x]
|
||||
for (i in seq(along=xx)) clear.text(xx[i], yy[i])
|
||||
box()
|
||||
text(x=xx, y=yy, as.vector(unlist(x))[diff.x], cex=cex)
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
|
||||
control.text <- function(x, screen.n, cex=1,
|
||||
spread.name=deparse(match.call()[["x"]]))
|
||||
{
|
||||
#This is a real function that does its own work
|
||||
if (!missing(screen.n)) {screen(screen.n, new=F); par(plt=c(0,1,0,1))}
|
||||
x.old <- x[,]
|
||||
rc <- cell.rc.text(nrow(x))
|
||||
command <- expr.rc(x, rc)
|
||||
cat("> ", command, "\n", sep="", file="")
|
||||
eval(parse(text=readline()))
|
||||
if (!missing(screen.n)) {screen(screen.n, new=F); par(plt=c(0,1,0,1))}
|
||||
print.update.text(x, x.old=x.old, cex=cex, spread.name=spread.name)
|
||||
# print.text(x, cex=cex, spread.name=spread.name)
|
||||
invisible(x)
|
||||
}
|
||||
|
||||
|
||||
#text usage
|
||||
# device() # for example, x11(), or motif(), or win.graph()
|
||||
# x <- my.spread # copy my.spread to x
|
||||
##loop
|
||||
# print.text(x) # work with x
|
||||
# x <- control.text(x, screen) # screen is optional
|
||||
##end loop
|
||||
# my.spread <- x # copy revised x back to my.spread
|
197
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd3d.how
Normal file
197
.emacs.d/elpa/ess-20160208.453/etc/other/S-spread/sprd3d.how
Normal file
@@ -0,0 +1,197 @@
|
||||
The emacs spread.frame device handler
|
||||
|
||||
Richard M. Heiberger
|
||||
|
||||
|
||||
There are two variants in the usage of this emacs spread.frame device
|
||||
handler. Both use the same command file: S-spread.el. One variant is
|
||||
stand-alone. The other works with S-mode. Both are written in emacs
|
||||
19.29 to use the comint.el package. They will not work in emacs 18.
|
||||
|
||||
A. Stand-alone Usage
|
||||
|
||||
1. Create a .Data subdirectory in the directory you will be using, say
|
||||
`myclass' and `myclass/.Data'. Get into the dired buffer of the
|
||||
directory `myclass'. Any other buffer will cause the terminal to beep.
|
||||
|
||||
|
||||
2. From the dired buffer enter (on my computer):
|
||||
M-x load-file <RET> /disk5/rmh/sprd3d/S-spread.el
|
||||
Edit the pathname for your computer. Any other buffer than the dired
|
||||
buffer will cause the terminal to beep. You will be prompted "S or
|
||||
Splus? ". "Splus" has been filled in as the default. Edit the
|
||||
command name if necessary, inserting a full pathname if appropriate,
|
||||
then hit carriage return.
|
||||
|
||||
This leaves the window showing the .Registry buffer in Spread mode. If
|
||||
you previously had a .Registry in that directory, it appears in the
|
||||
buffer. If you have never used the spread.frame handler in that
|
||||
directory, then a new .Registry has been created for you.
|
||||
|
||||
You also have a buffer called *Splus* (or *S*) in Inferior Spread mode
|
||||
in which Splus (or S) is running.
|
||||
|
||||
|
||||
NOTES for Stand-alone Version
|
||||
|
||||
If you were previously running Splus in buffer *Splus* in Inferior Spread mode
|
||||
and accidentally killed the Splus process (for example, with the q()
|
||||
command), you are still using that buffer and the Splus process has been
|
||||
restarted.
|
||||
|
||||
If you have a buffer named *Splus* not associated with a process, for
|
||||
example a file you are editing, emacs will use that buffer for the
|
||||
Inferior Spread mode.
|
||||
|
||||
If you have a running Inferior Spread process, a shell process, or any
|
||||
other process, in a buffer named *Splus*, the terminal will beep.
|
||||
|
||||
|
||||
|
||||
B. S-mode Usage
|
||||
|
||||
1. Create a .Data subdirectory in the directory you will be using, say
|
||||
`myclass' and `myclass/.Data'. Get into the dired buffer of the
|
||||
directory `myclass' and start S-mode with M-x S.
|
||||
|
||||
|
||||
2. From the *S* buffer that S-mode has started enter (on my computer):
|
||||
M-x load-file <RET> /disk5/rmh/sprd3d/S-spread.el
|
||||
Edit the pathname for your computer. Any other buffer than the *S* buffer
|
||||
will cause the terminal to beep.
|
||||
|
||||
This leaves the window showing the .Registry buffer in Spread mode.
|
||||
If you previously had a .Registry in that directory, it appears in the
|
||||
buffer. If you have never used the spread.frame handler in that
|
||||
directory, then a new .Registry has been created for you.
|
||||
|
||||
|
||||
NOTES FOR BOTH VERSIONS
|
||||
|
||||
S/Splus thinks it is in charge and does not know about emacs. Emacs with
|
||||
comint attempts to coordinate its timing with Splus by sending commands to
|
||||
Splus with (comint-send-input) and waiting for their completion with
|
||||
(accept-process-output). If for any reason an out-of-date display of a
|
||||
buffer appears, use ^Cv to bring up the current display. If things
|
||||
still look wrong, go to the *Splus* buffer and force a current display
|
||||
with ^Cr. You will be requested to type the name of the object to be
|
||||
displayed in the minibuffer. All buffers displaying views of that
|
||||
object, and the .Registry buffer will be updated.
|
||||
|
||||
Either usage of the spread.frame functions and the command file
|
||||
S-spread.el works with S Version 3, S Version 4, or Splus 3.3.
|
||||
|
||||
|
||||
|
||||
3. Start working in the .Registry buffer. Move to the macro section.
|
||||
a. Do "f" or [mouse-2] on the name of the spread.frame you want to see.
|
||||
Spread.frame names are listed in the macro section of the display.
|
||||
b. If no names appear, then you must add them.
|
||||
|
||||
|
||||
4. To add more spread.frames, for example the "xy" spread.frame, where the
|
||||
"xy" spread.frame already exists in the .Data:
|
||||
|
||||
a. Move to the *Splus* buffer. Enter "^Cr".
|
||||
b. The minibuffer will ask you for the name of a spread.frame.
|
||||
c. Enter the name of the object (for example xy (no quotes))
|
||||
or an expression for a 2-way rectangular slice (xy[,,2]) of a 3-way object.
|
||||
d. The "xy" spread.frame will appear in the buffer.
|
||||
|
||||
|
||||
5. To add a three-way spread.frame to the display from the *Splus* buffer
|
||||
|
||||
a. Create a 3-way array and make it a spread.frame:
|
||||
xs <- as.spread(array(1:12,dim=c(2,3,2)))
|
||||
b. Print it to the /tmp/spraxxxxx directory with:
|
||||
print.update.emacs.3d(xs)
|
||||
c. Move the cursor to the .Registry buffer. Place the cursor on the
|
||||
.Registry entry and press RETURN twice. The names for the slices
|
||||
will now appear in the **macro** section (if not, use ^Cv).
|
||||
d. Place the cursor on each of the slices' names and press f.
|
||||
e. The entire spread.frame can also be displayed by pressing "f"
|
||||
or [mouse-2] on its name.
|
||||
The window displaying the entire spread.frame is not active.
|
||||
Pressing RETURN will beep.
|
||||
f. The slices are active. Pressing RETURN on a cell entry will update
|
||||
the entire spread.frame and the display of the slices. Pressing RETURN
|
||||
on a macro keyword or a macro name in a slice buffer will activate the
|
||||
display and update of the macro for the entire spread.frame.
|
||||
|
||||
|
||||
6. Move between spread.frames with ^X o.
|
||||
|
||||
|
||||
7. To edit a spread.frame, place the cursor on a cell and press ENTER
|
||||
or [mouse-3]. The expression associated with the cell will be
|
||||
displayed in the mini-buffer. Edit it and press ENTER. The
|
||||
spread.frame in Splus will be updated, and all views of the object in
|
||||
emacs buffers will be updated.
|
||||
|
||||
|
||||
8. To execute a macro, place the cursor on the macro name and enter ^Cc.
|
||||
Don't use print() or cat() in macros; sink() is in use.
|
||||
|
||||
|
||||
The graphics device can be used for rectangular spread.frames, but does
|
||||
not yet work with three-way spread.frames.
|
||||
To use a graphics device for the spread.frame display (but no macros yet).
|
||||
|
||||
|
||||
9. Open a graphics device: x11(), iris4d(), motif(), etc.
|
||||
|
||||
|
||||
10. Add the names of the spread.frames to .Registry as described above.
|
||||
|
||||
|
||||
11. To place a spread.frame in the graphics device, put the cursor on the
|
||||
spread.frame name in the **macro** listing in .Registry, and press ^Cp
|
||||
The minibuffer will display
|
||||
> xy <- print.text( xy )
|
||||
Press ENTER and the device will show the xy spread.frame.
|
||||
|
||||
|
||||
12. To change a value in a spread.frame in the graphics device, put the
|
||||
cursor on the spread.frame name in the **macro** listing in .Registry,
|
||||
and press ^Cs
|
||||
The minibuffer will display
|
||||
> xy <- control.text( xy )
|
||||
Press ENTER, move the cursor into the graphics window, and click when the
|
||||
crosshair is on the cell you wish to change. Place the cursor in the *Splus*
|
||||
buffer, move to the end of the buffer by pressing ESC > . You will see
|
||||
the expression to be edited (prefixed with a ">") on the next to the last
|
||||
line. Move the cursor to that line, edit the value, and press ENTER.
|
||||
The graphics window will be updated.
|
||||
|
||||
|
||||
13. You can edit any emacs buffer spread.frame by switching to its
|
||||
buffer and pressing ENTER or [mouse-3] on the appropriate entry. You
|
||||
can edit any spread.frame in the graphics device, by switching to the
|
||||
.Registry buffer, confirming that the spread.frame is in the graphics
|
||||
window (or putting it there with ^Cp), and then entering ^Cs on the
|
||||
macro name in the .Registry buffer that matches the spread.frame.
|
||||
|
||||
|
||||
14. There is an additional feature in the spread.frame interface that
|
||||
is very useful for numerical rows or columns. When the cursor is
|
||||
placed on the dimnames row or column, the entire column or row is made
|
||||
available in the mini-buffer. Warning: expr() in the row or column
|
||||
will be evaluated and will no longer be expr().
|
||||
|
||||
|
||||
15. Character data. Character matrices work well as spread.frames.
|
||||
|
||||
|
||||
16. Warning: character or factor columns in data.frames.
|
||||
S likes to coerce character columns in data.frames to factors.
|
||||
Updating an entire factor column, or an entire row containing factor
|
||||
columns, may be dangerous because the revised values may not be in the
|
||||
levels(). The entire column may be replaced with NA values. Updating
|
||||
of individual character values is fine in character arrays that are
|
||||
not data.frames, or in data.frames where the length(expr(x)) ==
|
||||
prod(dim(x)). To get a character column into a data frame use
|
||||
my.frame$char <- character.value # remains character
|
||||
Using either
|
||||
my.frame[,"char"] <- character.value # coerced to factor
|
||||
my.frame <- cbind(my.frame,character.value) # coerced to factor
|
||||
won't work. Either of those forms coerces the values to factor.
|
2
.emacs.d/elpa/ess-20160208.453/etc/other/test
Normal file
2
.emacs.d/elpa/ess-20160208.453/etc/other/test
Normal file
@@ -0,0 +1,2 @@
|
||||
modify the test with a change.
|
||||
SJE: simple change.
|
4
.emacs.d/elpa/ess-20160208.453/etc/pkg-Maintainers
Normal file
4
.emacs.d/elpa/ess-20160208.453/etc/pkg-Maintainers
Normal file
@@ -0,0 +1,4 @@
|
||||
Xemacs: Rodney Sparapani -- no longer
|
||||
Debian: Dirk Eddelbuettel <edd@debian.org>
|
||||
RPM: Tom Moertel <tom@moertel.com>
|
||||
SuSe: Detlef Steuer <steuer@hsu-hh.de>
|
9
.emacs.d/elpa/ess-20160208.453/etc/pkg1/DESCRIPTION
Normal file
9
.emacs.d/elpa/ess-20160208.453/etc/pkg1/DESCRIPTION
Normal file
@@ -0,0 +1,9 @@
|
||||
Package: pkg1
|
||||
Type: Package
|
||||
Title: A sample package for testing ESS
|
||||
Version: 1.0
|
||||
Date: 2014-01-20
|
||||
Author: ESS Core
|
||||
Maintainer: <yourfault@somewhere.net>
|
||||
Description: A sample package for testing ESS
|
||||
License: GPL-2
|
1
.emacs.d/elpa/ess-20160208.453/etc/pkg1/NAMESPACE
Normal file
1
.emacs.d/elpa/ess-20160208.453/etc/pkg1/NAMESPACE
Normal file
@@ -0,0 +1 @@
|
||||
export(D1tr)
|
20
.emacs.d/elpa/ess-20160208.453/etc/pkg1/R/D1tr.R
Normal file
20
.emacs.d/elpa/ess-20160208.453/etc/pkg1/R/D1tr.R
Normal file
@@ -0,0 +1,20 @@
|
||||
D1tr <- function(y, x = 1)
|
||||
{
|
||||
## Purpose: discrete trivial estimate of 1st derivative.
|
||||
## ----------------------------------------------------------------------
|
||||
## Arguments: x is optional; let's say we don't like "'"
|
||||
## ----------------------------------------------------------------------
|
||||
## Author: Martin Maechler, ~ 1990
|
||||
n <- length(y)
|
||||
|
||||
if(length(x) == 1)
|
||||
c(y[2] - y[1], 0.5 * (y[-(1:2)] - y[-((n-1):n)]), y[n] - y[n-1])/x
|
||||
else {
|
||||
## Here, already using non-matching apostrophes, but developer mode
|
||||
## still seems to work ..
|
||||
if(n != length(x)) stop("lengths' of x & 'y' must equal")
|
||||
if(is.unsorted(x)) stop("'x' must be sorted !")
|
||||
c(y[2] - y[1], 0.5 * (y[-(1:2)] - y[-((n-1):n)]), y[n] - y[n-1]) /
|
||||
c(x[2] - x[1], 0.5 * (x[-(1:2)] - x[-((n-1):n)]), x[n] - x[n-1])
|
||||
}
|
||||
}
|
36
.emacs.d/elpa/ess-20160208.453/etc/pkg1/man/D1tr.Rd
Normal file
36
.emacs.d/elpa/ess-20160208.453/etc/pkg1/man/D1tr.Rd
Normal file
@@ -0,0 +1,36 @@
|
||||
\name{D1tr}
|
||||
\alias{D1tr}
|
||||
\title{Numerical Derivatives of (x,y) Data}
|
||||
\description{
|
||||
Compute the numerical derivatives of \eqn{f()} given
|
||||
observations \code{(x[i], y ~= f(x[i]))}.
|
||||
|
||||
\code{D1tr} is the \emph{\bold{tr}ivial} discrete first derivative
|
||||
using simple difference ratios.
|
||||
|
||||
This is \bold{far} from optimal and only kept here for reference.
|
||||
}
|
||||
\usage{
|
||||
D1tr(y, x = 1)
|
||||
}
|
||||
\arguments{
|
||||
\item{x,y}{numeric vectors of same length, supposedly from a model
|
||||
\code{y ~ f(x)}. For \code{D1tr()}, \code{x} can have length one
|
||||
and then gets the meaning of \eqn{h = \Delta x}.}
|
||||
}
|
||||
\value{
|
||||
\code{D1tr()} returns a numeric vector of the length of \code{y}.
|
||||
}
|
||||
\author{Martin Maechler, in 1992 (for S).}
|
||||
\seealso{\code{\link[sfsmisc]{D1D2}} which directly uses the 2nd
|
||||
derivative of the smoothing spline; \code{\link{smooth.spline}}.
|
||||
}
|
||||
\examples{
|
||||
set.seed(330)
|
||||
x <- sort(runif(500, 0,10))
|
||||
y <- sin(x) + rnorm(500)/100
|
||||
f1 <- D1tr(x=x,y=y)
|
||||
plot(x,f1, ylim = range(c(-1,1, f1)))
|
||||
curve(cos(x), col=3, add= TRUE)
|
||||
}
|
||||
\keyword{smooth}
|
BIN
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.doc
Normal file
BIN
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.doc
Normal file
Binary file not shown.
2569
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.ps
Normal file
2569
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.ps
Normal file
File diff suppressed because it is too large
Load Diff
137
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.rtf
Normal file
137
.emacs.d/elpa/ess-20160208.453/etc/sas-keys.rtf
Normal file
@@ -0,0 +1,137 @@
|
||||
{\rtf1\ansi\deff0\adeflang1025
|
||||
{\fonttbl{\f0\froman\fprq2\fcharset0 Times New Roman;}{\f1\froman\fprq2\fcharset0 Times New Roman;}{\f2\froman\fprq2\fcharset0 Times New Roman;}{\f3\fnil\fprq2\fcharset0 Bitstream Vera Sans;}{\f4\fnil\fprq2\fcharset0 Lucidasans;}{\f5\fnil\fprq0\fcharset0 Lucidasans;}}
|
||||
{\colortbl;\red0\green0\blue0;\red128\green128\blue128;}
|
||||
{\stylesheet{\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033\snext1 Default;}
|
||||
{\s2\sa120\cf0{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031\sbasedon1\snext2 Text body;}
|
||||
{\s3\cf0{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af5\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031\sbasedon2\snext3 List;}
|
||||
{\s4\sb120\sa120\cf0{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af5\afs20\lang255\ai\ltrch\dbch\af3\afs20\langfe255\ai\loch\f0\fs20\lang1031\i\sbasedon1\snext4 Caption;}
|
||||
{\s5\cf0{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af5\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031\sbasedon1\snext5 Index;}
|
||||
{\s6\cf0{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031\sbasedon2\snext6 Table Contents;}
|
||||
{\s7\cf0\qc{\*\hyphen2\hyphlead2\hyphtrail2\hyphmax0}\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\ai\ab\loch\f0\fs24\lang1031\i\b\sbasedon6\snext7 Table Heading;}
|
||||
{\*\cs9\cf0\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031 WW-Absatz-Standardschriftart;}
|
||||
{\*\cs10\cf0\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031 WW-Absatz-Standardschriftart1;}
|
||||
{\*\cs11\cf0\rtlch\af4\afs24\lang255\ltrch\dbch\af3\afs24\langfe255\loch\f0\fs24\lang1031 WW-Default Paragraph Font;}
|
||||
}
|
||||
{\info{\title Help}{\author Rodney Sparapani}{\creatim\yr2001\mo4\dy26\hr10\min22}{\operator Rodney Sparapani}{\revtim\yr2001\mo4\dy26\hr10\min25}{\printim\yr2004\mo1\dy27\hr10\min21}{\comment StarWriter}{\vern6450}}\deftab720
|
||||
{\*\pgdsctbl
|
||||
{\pgdsc0\pgdscuse195\lndscpsxn\pgwsxn15840\pghsxn12240\marglsxn720\margrsxn720\margtsxn720\margbsxn720\pgdscnxt0 Default;}}
|
||||
{\*\pgdscno0}\landscape\paperh12240\paperw15840\margl720\margr720\margt720\margb720\sectd\sbknone\lndscpsxn\pgwsxn15840\pghsxn12240\marglsxn720\margrsxn720\margtsxn720\margbsxn720\ftnbj\ftnstart1\ftnrstcont\ftnnar\aenddoc\aftnrstcont\aftnstart1\aftnnrlc
|
||||
\pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 Unix key definitions for PC/Mac keyboard}
|
||||
\par \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\par \trowd\trqr\trrh863\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1105\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx2201\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3308\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4423\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4958\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx6064\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7180\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8285\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9401\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9973\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11079\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12194\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx13300\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F1\line Help}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Refresh}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3\line Submit}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4\line Program}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5\line Log}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6\line Listing}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7\line Text}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8\line Shell}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 View}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F10}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Log-Toggle}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F11}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 File-type-2}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F12\line Graph}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 PC key definitions for PC/Mac keyboard}
|
||||
\par
|
||||
\par \trowd\trqr\trrh863\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1105\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx2201\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3308\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4423\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4958\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx6064\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7180\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8285\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9401\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9973\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11079\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12194\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx13300\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F1\line Help}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Refresh}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3\line Shell}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4\line Text}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5\line Program}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6\line Log}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7\line Listing }
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8\line Submit}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 View}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F10}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Log-Toggle}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F11}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 File-type-2}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F12\line Graph}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Unix key definitions for Thinkpad keyboard}
|
||||
\par
|
||||
\par \trowd\trqr\trrh863\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1588\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3177\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4768\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx5624\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7212\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8803\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx10408\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11998\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12823\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Refresh}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3\line Submit}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4\line {\fs18 Program}}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5\line Log}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6\line Listing}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7\line Text}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8\line Shell}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 View}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 PC key definitions for Thinkpad keyboard}
|
||||
\par
|
||||
\par \trowd\trqr\trrh863\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1588\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3177\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4768\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx5624\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7212\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8803\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx10408\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11998\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12823\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Refresh}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3\line Shell}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4\line Text}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5}
|
||||
\par \pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs18\langfe255\loch\f2\fs18\lang1033 {\loch\f2\fs18\lang1033\i0\b0 Program}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6\line Log}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7\line Listing}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8\line Submit}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 View}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 Unix key definitions for Sun keyboard (cut out the numbered boxes and leave the dividers between F4/F5 and F8/F9)}
|
||||
\par
|
||||
\par
|
||||
\par \trowd\trqr\trrh1070\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1105\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx2201\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3308\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4423\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4958\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx6064\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7180\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8285\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9401\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9973\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11079\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12194\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx13300\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F1}
|
||||
\par \pard\plain \intbl\ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F10}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F11}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F12}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 Help Refresh Submit Program Log Listing Text Shell Viewtable Log-Toggle File-type-2 Viewgraph}
|
||||
\par
|
||||
\par {\loch\f2\fs20\lang1033\i0\b0 PC key definitions for Sun keyboard (cut out the numbered boxes and leave the dividers between F4/F5 and F8/F9)}
|
||||
\par
|
||||
\par
|
||||
\par \trowd\trqr\trrh1070\trpaddft3\trpaddt0\trpaddfl3\trpaddl0\trpaddfb3\trpaddb0\trpaddfr3\trpaddr0\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx1105\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx2201\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx3308\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4423\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx4958\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx6064\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx7180\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx8285\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9401\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx9973\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx11079\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx12194\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clvertalt\cellx13300\clbrdrt\brdrs\brdrw1\brdrcf1\clbrdrl\brdrs\brdrw1\brdrcf1\clbrdrb\brdrs\brdrw1\brdrcf1\clbrdrr\brdrs\brdrw1\brdrcf1\clvertalt\cellx14400
|
||||
\pard\intbl\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F1}
|
||||
\par \pard\plain \intbl\ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F2}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F3}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F4}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F5}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F6}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F7}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F8}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F9}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F10}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F11}
|
||||
\cell\pard\plain \intbl\ltrpar\s1\qc\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 \line F12}
|
||||
\cell\row\pard \pard\plain \ltrpar\s1\ql\rtlch\af2\afs20\lang255\ltrch\dbch\af2\afs20\langfe255\loch\f2\fs20\lang1033 {\loch\f2\fs20\lang1033\i0\b0 Help Refresh Shell Text Program Log Listing Submit Viewtable Log-Toggle File-type-2 Viewgraph}
|
||||
\par }
|
283
.emacs.d/elpa/ess-20160208.453/etc/sje-ess-notes.txt
Normal file
283
.emacs.d/elpa/ess-20160208.453/etc/sje-ess-notes.txt
Normal file
@@ -0,0 +1,283 @@
|
||||
Stephen Eglen's notes on future changes to ESS -*- org -*-
|
||||
|
||||
* Problem with ESS infrastructure and Martin away? Email isg@math.ethz.ch
|
||||
* ess-history-file
|
||||
|
||||
needs documenting and possibly updating:
|
||||
|
||||
From: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
To: Erik Iverson <eriki@ccbr.umn.edu>
|
||||
Comments: In-reply-to Erik Iverson <eriki@ccbr.umn.edu>
|
||||
message dated "Wed, 20 Apr 2011 09:36:26 -0500."
|
||||
Date: Tue, 26 Apr 2011 09:01:29 +0100
|
||||
Cc: Feng Li <m@feng.li>, ess-help@stat.math.ethz.ch
|
||||
Subject: Re: [ESS] ESS and .Rhistory
|
||||
Sender: ess-help-bounces@r-project.org
|
||||
|
||||
Dear Erik, Feng,
|
||||
|
||||
Thanks for this -- I was blissfully unaware about this persistence of
|
||||
history across R sessions. Howabout if we change the semantics of
|
||||
ess-history-file to be:
|
||||
|
||||
nil -- do not attempt to read/write a history file
|
||||
t -- use the default naming scheme for loading the history
|
||||
"some.string" -- use this value as the filename.
|
||||
|
||||
|
||||
Stephen
|
||||
> Feng,
|
||||
>
|
||||
> On 04/20/2011 09:00 AM, Feng Li wrote:
|
||||
> > Dear list,
|
||||
> >
|
||||
> > I tried to change the ESS default R history to a permanent file so
|
||||
> > that ESS does not generate .Rhistory everywhere. I tried both
|
||||
> >
|
||||
> > (setq ess-history-directory "~/.R/history")
|
||||
> >
|
||||
> > and
|
||||
> >
|
||||
> > (setq ess-history-file "~/.R/history/.Rhistory")
|
||||
>
|
||||
> If I recall correctly, it's because of the way the ess-history-file
|
||||
> variable is set in the ESS code. The following works for me:
|
||||
>
|
||||
> (defun ei-no-rhistory ()
|
||||
> (setq ess-history-file "/dev/null"))
|
||||
>
|
||||
> (add-hook 'inferior-ess-mode-hook 'ei-no-rhistory)
|
||||
|
||||
* completion of functions within buffers
|
||||
|
||||
From: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
To: ESS-help@stat.math.ethz.ch
|
||||
Date: Tue, 22 Jun 2010 14:00:25 +0100
|
||||
Cc: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
Subject: [ESS] request for comments: completion within .R buffers
|
||||
Sender: ess-help-bounces@stat.math.ethz.ch
|
||||
|
||||
Rodney recently kindly polled ess-help, and a summary of the results can
|
||||
be seen in the SVN sources at:
|
||||
|
||||
https://svn.r-project.org/ESS/trunk/rsn.txt
|
||||
|
||||
One thing that came up was (thanks Ista Zhan):
|
||||
|
||||
Function/variable completion in script files (maybe this already is
|
||||
supposed to work, but for me completion only works in interactive
|
||||
sessions).
|
||||
|
||||
Below is some suggested code to implement this, based on a hint from
|
||||
Deepayan. If you press TAB at the start of the line, you still get
|
||||
standard indentation, but if you are already typing something, e.g.
|
||||
write.t
|
||||
|
||||
then hitting TAB will complete to write.table
|
||||
|
||||
Hitting TAB again, will then bring up a *Completions* window showing
|
||||
(for me):
|
||||
|
||||
Possible completions are:
|
||||
write.table
|
||||
write.table0
|
||||
|
||||
I don't like the *Completions* window hanging around, but apart from
|
||||
that, is that the sort of completion people would like? Erik Iverson
|
||||
mentioned something related:
|
||||
|
||||
I think ESS is very feature complete at this point. The only thing
|
||||
I've looked at that seems interesting is some sort of 'intellisense'
|
||||
feature that uses R's built-in completion mechanism to temporarily
|
||||
display available completions using something like company-mode,
|
||||
autocomplete, or completion-ui. I had at one point something that
|
||||
almost worked, but I believe the library it was built in,
|
||||
company-mode, has now changed significantly.
|
||||
|
||||
but I've not explored those options.
|
||||
|
||||
Code/ideas welcome!
|
||||
|
||||
Stephen
|
||||
|
||||
----------------------------------------------------------------------
|
||||
|
||||
(defun ess-indent-or-complete (&optional whole-exp)
|
||||
(interactive "P")
|
||||
"Function bound to TAB key in R mode buffers.
|
||||
If at the start of the line, or numeric prefix provided, call
|
||||
`ess-indent-command', otherwise try to complete object at point."
|
||||
(if (or whole-exp
|
||||
(save-excursion
|
||||
(skip-chars-backward " \t")
|
||||
(bolp)))
|
||||
(ess-indent-command whole-exp)
|
||||
(ess-complete-object-name)))
|
||||
|
||||
(add-hook 'ess-mode-hook
|
||||
'(lambda () (local-set-key "\t" 'ess-indent-or-complete)))
|
||||
|
||||
|
||||
* ess-eldoc.el
|
||||
|
||||
** Switch to use R-mode-hook, rather than ess-mode-hook
|
||||
|
||||
** Document in the info node.
|
||||
|
||||
* Debugger
|
||||
|
||||
Would like to implement a debugger akin to Norm Matloff's work:
|
||||
|
||||
http://cran.r-project.org/web/packages/edtdbg/index.html
|
||||
|
||||
http://www.stats.uwo.ca/faculty/murdoch/software/debuggingR/
|
||||
|
||||
Norm posted that he had started work on ESS, but had to abandon it.
|
||||
|
||||
|
||||
* Comint so slow? ess-eval-visibly-p should be t again.
|
||||
|
||||
Why is comint so slow when passing code line by line? Markus Triska
|
||||
recently looked at this:
|
||||
|
||||
To: ess-help@stat.math.ethz.ch
|
||||
connect(): No such file or directory
|
||||
From: Markus Triska <markus.triska@gmx.at>
|
||||
Date: Sun, 16 May 2010 13:59:57 +0200
|
||||
Subject: Re: [ESS] ESS on Mac slower than R.app?
|
||||
Sender: ess-help-bounces@stat.math.ethz.ch
|
||||
|
||||
Hi Rodney,
|
||||
|
||||
Rodney Sparapani <rsparapa@mcw.edu> writes:
|
||||
|
||||
> I think if you update to the latest version of ESS this problem will
|
||||
> go away. See the previous discussion of a very similar GNU Emacs bug
|
||||
> fix at https://stat.ethz.ch/pipermail/ess-bugs/2009q4/000584.html
|
||||
|
||||
I think ess-eval-visibly-p should remain true by default, as it is quite
|
||||
useful. If you change the accept-process-output call in
|
||||
ess-eval-linewise to:
|
||||
|
||||
(accept-process-output sprocess 0 timeout-ms)
|
||||
|
||||
(the difference being that you explicitly state to wait for input from
|
||||
"sprocess"), the test case works instantly also with ess-eval-visibly-p.
|
||||
|
||||
All the best,
|
||||
Markus
|
||||
|
||||
* Funny indentation if semicolon follows brace:
|
||||
|
||||
From: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
To: Paul Burkander <paul@burkander.com>
|
||||
Comments: In-reply-to Paul Burkander <paul@burkander.com>
|
||||
message dated "Sat, 04 Jun 2011 10:17:03 -0400."
|
||||
Date: Mon, 06 Jun 2011 10:35:27 +0100
|
||||
Cc: ess-help@r-project.org
|
||||
Subject: Re: [ESS] ess-indent-exp follow OWN style?
|
||||
Sender: ess-help-bounces@r-project.org
|
||||
|
||||
> I think it must be ess-electric-brace, and I think it warrants a bug report.
|
||||
>
|
||||
> The behavior is the same in R and Stata (though I don't know if it
|
||||
> would ever come up in R)
|
||||
>
|
||||
> Typing any line (excluding comments) that ends in { sets the
|
||||
> indentation of the next line to ess-indent-level
|
||||
> Typing any line (excluding comments) that ends in {; sets the
|
||||
> indentation of the next line to so that the first character is below
|
||||
> the preceding semicolon.
|
||||
>
|
||||
> I know basically nothing about Lisp, otherwise I'd like to try to
|
||||
> debug this thing. It seems like an important replicable issue that
|
||||
> warrants a bug report.
|
||||
|
||||
Thanks; I can see this behaviour in R mode. As I don't think its a
|
||||
common idiom in R to write something like
|
||||
|
||||
for (i in seq) {;
|
||||
...
|
||||
|
||||
I'm afraid its not high enough on my priority list to fix right now
|
||||
(sorry, too many other things already need fixing in ESS), but
|
||||
I will make a note of it. Is this biting other users?
|
||||
|
||||
Stephen
|
||||
|
||||
** is ess-electric-brace working okay? should reindent line?
|
||||
|
||||
* Handing the *ESS* buffer
|
||||
|
||||
Is the *ESS* buffer necessary for end users? If not, have a toggle to
|
||||
switch it off.
|
||||
|
||||
From: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
Date: Mon, 6 Jun 2011 22:12:08 +0100
|
||||
|
||||
> Re: the *ESS* buffer, how much of a pain is it? I recall also
|
||||
> finding it a bit offputting seeing this many years ago, and in all
|
||||
> my years of developing ESS, I for one have yet to find reason of
|
||||
> inspecting it! I imagine other developers may differ -- but one
|
||||
> thing I could suggest to other core members is having a variable
|
||||
> to inhibit this buffer?
|
||||
|
||||
This could be as simple as having a variable ess-dribble-buffer
|
||||
which if nil, means that the buffer is not created, otherwise, the
|
||||
variable contains (as a string) the name of the buffer to use, which
|
||||
defaults to "*ESS*". It could even be " *ESS*" so that it doesn't
|
||||
appear in buffer lists, but is there and will be included into
|
||||
reports generated by ess-submit-bug-report.
|
||||
|
||||
|
||||
* Add ess-r-versions-list
|
||||
|
||||
Subject: Re: [ESS] Customisation of ess-r-versions or ess-r-versions-list
|
||||
From: John Maindonald <john.maindonald@anu.edu.au>
|
||||
Date: Thu, 18 Aug 2011 10:19:44 +1000
|
||||
Cc: ess-help@stat.math.ethz.ch
|
||||
To: Stephen Eglen <S.J.Eglen@damtp.cam.ac.uk>
|
||||
|
||||
On 18/08/2011, at 5:38 AM, Stephen Eglen wrote:
|
||||
|
||||
>> Yes,
|
||||
>> (setq ess-s-versions-list
|
||||
>> '( ("R64" "/usr/bin/R64")
|
||||
>> ("R32" "/usr/bin/R32")))
|
||||
>> works. The buffer for R64 is however called *S+6*. No doubt there is
|
||||
>> some variable that one can set that will fix this; I have not
|
||||
>> investigated.
|
||||
> I don't recall ever doing this for R, but this was quite a few years
|
||||
> ago. Did it ever work for you in earlier versions of ESS?
|
||||
|
||||
The lines that I had commented out had 'ess-r-versions-list'. If this variable
|
||||
has never been available, this would be something that I tried by analogy
|
||||
with 'ess-s-versions-list' and never did work.
|
||||
|
||||
If 'ess-s-versions-list' is to stay, it would seem to be cleanest to have a
|
||||
matching 'ess-r-versions-list' also, following the precedent of
|
||||
'ess-s-versions' and 'ess-r-versions'. An advantage of this way of doing
|
||||
things (an 'ess-r-versions-list'), for some users at least, is that it is explicit
|
||||
about the command line statement that is invoked.
|
||||
|
||||
> One can have defvar in place of setq. Does it matter which one uses?
|
||||
> Better to use setq -- as it will always update the value. By contrast:
|
||||
>
|
||||
> (defvar apple 1)
|
||||
> (defvar apple 2)
|
||||
>
|
||||
> Evaluate both lines above, in order, and check "apple" -- it has the
|
||||
> value 1.
|
||||
>
|
||||
> Stephen
|
||||
|
||||
|
||||
John Maindonald email: john.maindonald@anu.edu.au
|
||||
phone : +61 2 (6125)3473 fax : +61 2(6125)5549
|
||||
Centre for Mathematics & Its Applications, Room 1194,
|
||||
John Dedman Mathematical Sciences Building (Building 27)
|
||||
Australian National University, Canberra ACT 0200.
|
||||
http://www.maths.anu.edu.au/~johnm
|
||||
|
||||
* Toolbar is missing from file.Rt transcript buffers
|
||||
Add toolbar?
|
55
.emacs.d/elpa/ess-20160208.453/etc/slow-long-output.R
Normal file
55
.emacs.d/elpa/ess-20160208.453/etc/slow-long-output.R
Normal file
@@ -0,0 +1,55 @@
|
||||
### Example modified from Paul Johnson's post to ESS-help, Nov.25, 2013
|
||||
op <- options("max.print")
|
||||
|
||||
##' construct (random) character vector of length n, of about 10 characters each
|
||||
mkCh <- function(n) {
|
||||
if(getOption("max.print") <= n) options(max.print = n + 1) ## <-
|
||||
if(n == 10) stop("error's message with apostrophe - work's in developer mode")
|
||||
N <- pmin(26,pmax(1, rpois(n, 10)))
|
||||
cbind(vapply(N, function(m) paste(sample(letters, m), collapse=""), ""))
|
||||
}
|
||||
|
||||
set.seed(1)
|
||||
y <- mkCh(9999)
|
||||
system.time(print(y))
|
||||
## R CMD BATCH slow-long-output.R && grep -A 1 -B 1 '^ *user *sys' slow-long-output.Rout
|
||||
## user system elapsed
|
||||
## 0.059 0.010 0.070 -- MM@lynne R CMD BATCH
|
||||
## 0.040 0.014 12.762 -- MM@lynne(2015) ESS 15.09-1 [git: dd226e2027..]
|
||||
## 0.027 0.027 1.945 -- MM@lynne(2015) ESS 14.09 [svn: 6041]
|
||||
## 0.120 0.138 3.225 -- MM@lynne(2013-12) ESS 13.09-1 [svn: 5930]
|
||||
##---
|
||||
## 0.124 0.097 52.540 -- MM@lynne ESS svn r 5909; incl font-locking, tracebug
|
||||
## 0.128 0.080 57.305 ditto
|
||||
## 0.139 0.088 54.770 -- sfs@lynne ESS 13.09 (emacs 24.3.1 GTK+)
|
||||
## --
|
||||
## 0.102 0.075 4.685 -- MM@lynne ESS 5.14 (emacs 24.3.1 incl font-lock!)
|
||||
## 0.091 0.078 4.683 -- " ESS 12.04-4 [rev. 4896 (2012-06-07)]
|
||||
## 0.123 0.063 4.638 -- " ESS 12.09-2 [rev. 5395 (2013-01-10)]
|
||||
## 0.117 0.118 3.358 -- " ESS 13.05 [rev. 5574 (2013-05-14)]
|
||||
## ^^^^^ clearly a bit faster !
|
||||
|
||||
set.seed(23456)
|
||||
y <- mkCh(50000)
|
||||
system.time(print(y))
|
||||
## user system elapsed
|
||||
## 0.255 0.089 0.345 -- BATCH MM@lynne
|
||||
## 0.035 0.138 27.935 -- MM@lynne(2015) ESS 15.09-1 [git: dd226e2027..]
|
||||
## .... but sometimes also fast, or considerably slower:
|
||||
## 0.049 0.112 1.037
|
||||
## 0.036 0.129 103.253
|
||||
## 0.157 0.107 11.356 -- MM@lynne(2015) ESS 14.09 [svn: 6041]
|
||||
## 0.685 0.369 1664.557 -- MM@lynne ESS svn r 5909 ...
|
||||
## 0.760 0.398 1643.608 -- ..@lynne ESS 13.09
|
||||
## 0.590 0.510 33.349 -- " ESS 13.05 [rev. 5574 (2013-05-14)]
|
||||
## 0.565 0.548 28.251 " "
|
||||
## 0.598 0.450 27.804 " "
|
||||
|
||||
|
||||
## Don't even think of trying this with ESS, currently:
|
||||
y <- mkCh(200000)
|
||||
system.time(print(y))
|
||||
## user system elapsed
|
||||
## 1.013 0.284 1.300 -- BATCH MM@lynne
|
||||
|
||||
options(op)
|
Reference in New Issue
Block a user