Interrupting an R command
1
0
Entering edit mode
@january-weiner-3999
Last seen 9.6 years ago
Dear all, I have recklessly started an R command (randomForest from the randomForest library) and I was foolish enough not to save my workspace earlier (a typo and rf runs on a data set of 1000 x 100 instead of 100 x 10). I don't want to kill R -- I don't want to lose the changes to the workspace. I would like to interrupt the random forests command only without killing the session; however, it does not react to ^C (control-C). Are there any other options available? Killing R, but with forcing it to save the workspace first would be fine as well. The platform: Linux / Ubuntu 10.04; R version 2.10.1 (2009-12-14); randomForest library version: randomForest 4.5-36 Best regards, j. --
• 2.9k views
ADD COMMENT
0
Entering edit mode
@kasper-daniel-hansen-2979
Last seen 9 months ago
United States
There is no other way. How effective C-c is depends a lot on the code you are running. In C code for example the author has to place a command like checkUserInterrupt() once in a while. Some packages don't do this, making them impossible to interrupt. Some packages do this inside a for loop, only checking for example every 1000 iterations. In that case you have to wait until the code reaches the interrupt check, which may take forever if the system is starting to swap a lot. I don't know which category randomForest belongs to. Kasper On Wed, Oct 6, 2010 at 9:06 AM, January Weiner <january.weiner at="" mpiib-berlin.mpg.de=""> wrote: > Dear all, > > I have recklessly started an R command (randomForest from the > randomForest library) and I was foolish enough not to save my > workspace earlier (a typo and rf runs on a data set of 1000 x 100 > instead of 100 x 10). > > I don't want to kill R -- I don't want to lose the changes to the workspace. > > I would like to interrupt the random forests command only without > killing the session; however, it does not react to ^C (control-C). > > Are there any other options available? Killing R, but with forcing it > to save the workspace first would be fine as well. > > The platform: Linux / Ubuntu 10.04; R version 2.10.1 (2009-12-14); > randomForest library version: randomForest 4.5-36 > > Best regards, > > j. > > > > -- > > _______________________________________________ > Bioconductor mailing list > Bioconductor at stat.math.ethz.ch > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor >
ADD COMMENT
0
Entering edit mode
Dear Kasper, I am trying to move over to 64-bit R (using the latest version R 2.12.0). It seems BioC packages install and work well on the most part. I tried installing Rgraphviz from source but realized that I would need a 64-bit version of graphviz itself. It appears that they only provide 32-bit binaries on their webpage. I noticed your posts on the graphviz-devel forum earlier this year. Have you been able to find or build a 64-bit version of the graphviz binaries for use with Rgraphviz? Any help would be most appreciated. Thanks, Fraser Fraser Sim, PhD Assistant Professor of Pharmacology and Toxicology University at Buffalo 119 Farber Hall Buffalo, NY 14214 T: (716) 829-2151 fjsim at buffalo.edu Confidentiality Notice: This message, including any atta...{{dropped:7}}
ADD REPLY
0
Entering edit mode
Answering my own post. I found a page http://www.stats.ox.ac.uk/~ripley/Win64/W64porting.html which has a link to a 64-bit abridged version of graphviz which has been built for 64-bit windows. Here's how I installed the package: 1. Extracted the acrhive (http://www.stats.ox.ac.uk/pub/Rtools/goodies/Win64No_/) to a folder on my PC. 2. Changed PATH environment variable to point to new location of graphviz 3. used biocLite("Rgraphviz") to install the 64-bit binary (note: the package would not install from source) 4. run test and was able to plot graph according to example code in Rgraphviz help Fraser -----Original Message----- From: bioconductor-bounces@stat.math.ethz.ch [mailto:bioconductor-bounces at stat.math.ethz.ch] On Behalf Of Fraser Sim Sent: Friday, October 22, 2010 4:09 PM To: 'Kasper Daniel Hansen' Cc: 'BioC' Subject: [BioC] 64-bit binary of graphviz for R 2.12.0 (x64) Dear Kasper, I am trying to move over to 64-bit R (using the latest version R 2.12.0). It seems BioC packages install and work well on the most part. I tried installing Rgraphviz from source but realized that I would need a 64-bit version of graphviz itself. It appears that they only provide 32-bit binaries on their webpage. I noticed your posts on the graphviz-devel forum earlier this year. Have you been able to find or build a 64-bit version of the graphviz binaries for use with Rgraphviz? Any help would be most appreciated. Thanks, Fraser _______________________________________________ Bioconductor mailing list Bioconductor at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/bioconductor Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
ADD REPLY

Login before adding your answer.

Traffic: 972 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6