similar to: How to see the previous commands after save workspace/load workspace ?

Displaying 20 results from an estimated 4000 matches similar to: "How to see the previous commands after save workspace/load workspace ?"

2002 Sep 19
3
savehistory directories and quitting R (PR#2038)
# # r-bugs@r-project.org # ###################################################### Because I work in different directories, but always want to save my .Rhistory in the same place, I have changed the system function savehistory to this: function (file = "D:/R50/.Rhistory") invisible(.Internal(savehistory(file))) When I use q() to quit R, and it asks me whether I want to
2004 Jul 28
2
problem with the .Rhistory
Hello, The history function doesn't seems to work when I am working with R. I have a .Rhistory file in my working directory and I have tried savehistory(file = ".Rhistory") or the command given in the history help : .Last <- function() if(interactive()) try(savehistory(".Rhistory")) and I get the same error message Error in
2002 Oct 21
1
savehistory directories and quitting R (PR#2038)
Thanks-- as Duncan Murdoch also noted, R_HISTFILE can be used to solve my problem, as below. BTW it's not easy to find out about R_HISTFILE in the help system or manuals, though, unless you already know it exists-- it only seems to be described under startup options, not things to do with history. However, Duncan's reply did hint at an inconsistency, in that savehistory() defaults to
2003 May 14
1
savehistory not working properly in R?
Dear R users, I have a .RData which contains .Last object as follows: .Last <- function () { savehistory(file = ".Rhistory") } In this directory, if I issue the following command Rterm --save < mycmds.q to execute commands in mycmds.q and to save results in .RData, I got the following error message towards the end of the execution: Error in savehistory(file) :
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 ->
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
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"))) } }
2011 Apr 13
5
Clearing Console; of weeks of codes!
Dear All: I do see I have weeks of codes in my console when I check with my arrow up keys. I have been clearing them with Control L but it seems to clear it clear the screen temporally. I do see the previous codes again when I open R the next day, after quitting the session! Q: How do I clear this? Thanks; YA -- View this message in context:
2004 Nov 02
4
Loadhistory problems
History files saved using nFile Save History do not open when using File Load History. I notice that when they are saved they do not seem to have a file extension and there is no option to chose an extension. Is this a problem. Other than this it seems so simple that I can't see what the problem is. I've tried using loadhistory and savehistory with the same problems. The syntax guide
2006 Mar 16
1
autoloading .RData files / .Rhistory file
NOTE: WinXP, R2.2.0 All, a while back I posted a question about using relative filereferencing. The responses have allowed me to successfully set up the following directory structure: ...\data\raw ...\data\derived ...\prog ...\lst ...\log In the \prog directory I have put an RGui.exe shortcut and "pointed it" at \prog as the "Start In" location. In the same
2000 Jun 29
3
Overal plot title after mfrow and .Rhistory questions.
Hello everyone, I had a few questions that I have not been able to figure out despite a lot of reading. 1) Adding a title to a multiplot figure: If I plot multiple plots with >par(mfrow=c(2,6)) how do I add an overall title to the figure, not the individual plots? 2) Saving histories on the fly: Is there a .Rhistory equivalent to >save.image() ? I would like to be able to save the
2013 Mar 31
1
Where does R store workspace and commands that load on startup
When I close R and answer yes to save workspace, R automatically loads it and apparently also the command history at start up. I would like to know where R stores this information. I know that I can save .RData and .Rhistory files, but I would like to know how(where) R stores this information automatically. I have not found any .RData or .Rhistory files associated with start up. I am running
2009 Dec 09
3
.Rhistory in R.app
Dear R users, I am having a minor but annoying issue with R.app. It doesn't retain the history information from the previous sessions. By "history," I mean a record of commands/functions entered into R rather than the list of objects--that is properly recorded in the .Rdata file as well as in a workspace file I save separately. System details: R version 2.9.0 R.app GUI 1.28 Mac OS
2010 Nov 14
3
How to permanently remove [Previously saved workspace restored]
Win 7 64 bit R version 2.11.1 (2010-05-31) How to permanently remove; [Previously saved workspace restored] > rm (list = ls( )) On next start it still displays; ..... [Previously saved workspace restored] There is a file keeping the previous data on Linux .Rdata How about on Windows? TIA B.R. Stephen L
2001 Sep 08
1
.Rhistory
It seems that when I choose not to save the workspace, R then chooses not to update the command history saved in the file .Rhistory. I can see a rationale for this, but I find it annoying; I might well want to be able to get at previous commands, even if I don't want to keep the objects created by these commands. Is there anyway of changing this behaviour --- i.e. to get R to save the
2009 Aug 02
1
Last expression entered by user
Hi, I am looking for a way to find out the last expression that was entered by the user, similar to ".Last.value", but for the unevaluated expression instead of the evaluated one. Example: > x <- 4 > x*x + 3 [1] 19 > .Last.value # that's the evaluated last expression [1] 19 # but I am looking for the unevaluated expression (".Last.expression", so to
2013 Mar 31
1
Storage of automatically loaded workspace and command files
When I close R and answer yes to save workspace, R automatically loads it and apparently also the command history at start up. I would like to know where R stores this information. I know that I can save .RData and .Rhistory files, but I would like to know how(where) R stores this information automatically. I have not found any .RData or .Rhistory files associated with start up. I am running
2011 May 30
2
Basic question about three factor Anova
Read the data using scan(): # # a1 a2 a3 a4 # ------------- ------------- ------------- ------------- # b1 b2 b3 b1 b2 b3 b1 b2 b3 b1 b2 b3 # --- --- --- --- --- --- --- --- --- --- --- --- # # c1: # 4.1 4.6 3.7 4.9 5.2 4.7 5.0 6.1 5.5 3.9 4.4 3.7 # 4.3 4.9
2008 Aug 14
1
the name of the current running script.r
Dear R users, is there a hack how to get the filename of the current script.r sourced/ran? My issue: I have a couple of scripts which were optimised and are placed in tens of directories. (I have a height.r script in 30 directories, a lines.r script in 25 directories and another flow.r script in 54 directories, growing). The script runs in the directory and does its job: sources data and creates
2008 Jan 21
1
Problems saving the workspace image
Hi! I use R with Windows for a long time. In the last week I change to Windows Vista. Now I can´t save the workspace image when I exit R. The system presents the following message “Unable to open .Rhistory”. Does anyone can help me? I thank you in advance, Ana [[alternative HTML version deleted]]