[R] Output and history
Peter Dalgaard BSA
p.dalgaard at biostat.ku.dk
Wed Jul 17 10:30:49 CEST 2002
Daniel Mastropietro <mastropi at uwalumni.com> writes:
> I have the following two questions, rergarding:
> 1) Is it possible to have the output of a command automatically
> displayed, without explicitly requesting it after the command, and
> without using the print() function? For example, I want to see the
> value of 'a' when I write for instance 'a <- rep(1,10)'.
> I tried setting the 'echo' option to TRUE but it has no effect on that.
No. "<-" creates an invisible object as its return value and they
don't print until you "visiblify" them. One standard device is to put
the whole thing in parentheses: (a <- rep(1,10)).
> 2) Is there a way to selectively recall a previously typed command
> based on the first characters of the command?
> I am thinking of something similar to this: if one types 'pl' at the
> prompt and then preses the up arrow key, only the commands starting
> with 'pl' will show up in the command line.
On Unix(-alikes) with readline something like that is part of the
Ctrl-R mechanism. As far as I remember, the Windows console does not
implement this (but as Brian said: patched will be considered).
O__ ---- Peter Dalgaard Blegdamsvej 3
c/ /'_ --- Dept. of Biostatistics 2200 Cph. N
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
More information about the R-help