Displaying 20 results from an estimated 1000 matches similar to: "pattern in history"
2002 Apr 30
1
followup -- deficiencies in readline capability
Why would R lack history capability?
Someone in a private electronic mail message suggested the possibility
that I was running R in a non-writable directory. This is not the
case, as the following logfile shows (where "$ " is my shell prompt):
$ ls -ld `pwd`
drwxrwxrwx 15 sys sys 2560 Apr 30 08:10 /tmp
$ R --vanilla
R : Copyright 2002, The R Development Core Team
2006 Apr 13
1
bash-like history mechanism and prompt settings
Hi,
I have a couple of questions:
* would it be possible to add more information on the history, for
example the number of the command and a timestamp. With the number of
command, one could do some stuff like in a terminal to recall a specific
command :
$ !45
and with the timestamp, one could imagine to ask for commands that were
typed in a given interval of time. For example :
R>
2004 Nov 08
1
can one evaluate an expression in a comment? (or insert resultsinto history?)
But that doesn't put the result into the history buffer, to be written
to a file only later when I savehistory(filename).
Bert Gunter also suggested ?capture.output and ?textConnection,
but I cannot see how to get text into the history buffer as comments,
but with evaluated expressions (values).
I know how to use paste, sink, write, etc. but nothing that I can see
inserts into the history
2006 Jan 12
3
hello World problem
Hi,
I'm trying to build a simple R package 'helloWorld' with just one
function that prints 'hello World' on the C side.
I agree that it is completely useless, but I just start mixing R and C.
My C file is as follows :
#include <stdio.h>
void helloWorld() {
printf("hello world !\n") ;
}
When I call it from R, here is what happens :
R>
2006 Feb 04
1
javascript device for R
Hi,
Has anyone started a javascript device for R.
I don't see something like that googling or at on
http://www.stat.auckland.ac.nz/~paul/R/devices.html
For example, using that graphics library :
http://www.walterzorn.com/jsgraphics/jsgraphics_e.htm
(I cc that message to the author.)
ps : this is not a feature request, i will do it. But if someone has
started that, let me know.
Romain
--
2006 Apr 26
2
environment
Hi,
Consider the code :
g <- function(){
print(.x)
.x <- 3
}
f <- function(){
environment(g) <- environment()
.x <- 2
g()
.x
}
> f()
[1] 2
[1] 2
I would like f() to return 3. How can I do that ? Am I completely out of
place ?
Doing that, I want to avoid to pass .x as a parameter in f, because in
real life .x is pretty big and g() is called over and over in a
2009 Feb 27
4
Optimize for loop / find last record for each person
I want to find the last record for each person_id in a data frame
(from a SQL database) ordered by date. Is there a better way than
this for loop?
for (i in 2:length(history[,1])) {
if (history[i, "person_id"] == history[i - 1, "person_id"])
history[i, "order"] = history[i - 1, "order"] + 1 # same person
else
history[i,
2006 Apr 25
10
www.r-project.org
Dear R users and developpers,
My question is adressed to both of you, so I choose R-help to post it.
Are there any plans to jazz up the main R website : http://www.r-project.org
The look it have now is the same for a long time and kind of sad
compared to other statistical package's website. Of course, the
comparison is not fair, since companies are paying web designers to draw
lollipop
2009 Sep 05
1
Is 'history' recorded in Rscript?
Hi,
I run the following command and try to save the commands that have
been run in the script. But it seems that no history is recorded. Is
it because that the history is not recorded in Rscript?
Regards,
Peng
$ Rscript savehistory.R
> f=tempfile()
> f
[1] "/tmp/Rtmp7WBjGG/file327b23c6"
> history()
Error in savehistory(file) : no history available to save
Calls: history ->
2006 May 26
2
combinatorial programming problem
Hola!
I am programming a class (S3) "symarray" for
storing the results of functions symmetric in its
k arguments. Intended use is for association indices
for more than two variables, for instance coresistivity
against antibiotics.
There is one programming problem I haven't solved, making an inverse
of the index function indx() --- se code below. It could for instance
return the
2012 Nov 08
1
Extract cell of many values from dataframe cells and sample from them.
Hi,
First my apologies for a non-working piece of code in a previous submission, I have corrected this error.
I'm doing is individual based modelling of a pathogen and it's host. The way I've thought of doing this is with two dataframes, one of the pathogen and it's genes and effector genes, and one of the host and it's resistance genes. During the simulation, these things
2009 Apr 27
2
save history only option under Linux
Hi,
I have a question regarding the R command options under Linux
Is there any options that I can save history only?
The only save option is --save, which saves both data and history.
I don't want to save temporary data, because sometimes the it takes much
time if the temp data is too big.
However I want to restore the history for my next R session..
If there is no such option that meets my
2012 Oct 10
2
history() does not work?
Hi,
> history()
gives Error in savehistory(file) : no history available to save
although I can scroll throu history with C^uparrow an C^downarrow.
How can I make history() work and/or show the current history in a file,
so that I can choose from previous commands?
The web did not throw up anything useful.
TIA --Christian
--
Christian W. Hoffmann,
CH - 8915 Hausen am Albis,
2004 Feb 02
2
Nearest Neighbor Algorithm in R -- again.
Several of the methods I use for analyzing large data sets, such as
WinGamma: determining the level of noise in data
Relief-F: estimating the influence of variables
depend on finding the k nearest neighbors of a point in a data frame or
matrix efficiently. (For large data sets it is not feasible to compute
the 'dist' matrix anyway.)
Seeing the proposed solution to "[R] distance
2008 Apr 13
1
.Rprofile, date tagging history, loading packages
Dear R-Helpers,
I'm fiddling with my .Rprofile in Windows XP & R 2.7.0 Beta. I prefer to
manually save my workspace but automatically save my command history via
the .Rprofile. That is working fine once I found that "utils::" was
required before the loadhistory & savehistory functions. What I would
like to do is add a separator line with a date between the histories of
each
2016 Apr 30
1
Declaring All Variables as Factors in GLM()
Hi guys,
I am running glm(y~., data = history,family=binomial)-essentially, logistic
regression for credit scoring (y = 0 or 1). The dataset 'history' has 14
variables, a few examples:
history <- read.csv("history.csv". header = TRUE)
1> 'income = 100,200,300 (these are numbers in my dataset; however
interpretation is that these are just tags or labels,for every
2003 Jan 20
1
Command History
I have compiled R under Solaris 7 (SunOS 5.7) with the readline-4.0
library linked. Command line editing appears to work, but I cannot
access command history. If I execute several commands in R, then type
"history()", I get the error message "Error in savehistory(file) : no
history available to save". Also, previous command recall (C-p) does
not seem to work. I am invoking
2013 Feb 07
1
Saving history across sessions
I have an environment variable `$R_HISTFILE` pointing to
`/home/my.username/.RHistory` and the following code in my `.Rprofile` in
my home directory:
.Last <- function() {
if (!any(commandArgs()=='--no-readline') && interactive()){
require(utils)
try(savehistory(Sys.getenv("R_HISTFILE")))
}
}
2009 Oct 25
2
Help with history() in Emacs/ESS
Hi Everyone,
I am a beginner running R 2.9.2 under Ubuntu and typically use Emacs w/ESS.
However, I am confused with history() command. When I issue command
history() in Emacs within an R session, this is what get:
> history()
Error in savehistory(file) : no history available to save
Similarly, history(max=10) command gives the same error message.
However, there is this In/Out Menu in the
2006 Mar 03
2
Command-line editing & history
Hi all,
Are there any plans to add more functionality to command-line editing and history editing on the command line?
In MATLAB (I know, comparisons are odious ...), you can type "p" and up-arrow on the command line and scroll through the recently entered commands beginning with "p". This is a very useful feature and something that I believe is not replicated in R.
Please