[R] automation of R? running an R script at a certain time each night?
Prof Brian Ripley
ripley at stats.ox.ac.uk
Fri May 23 18:47:58 CEST 2008
On Fri, 23 May 2008, Felipe Carrillo wrote:
> Hi:
> Edward, were you able to automate the process? if so,
> do you mind giving me a hint on how you did it? I am
> facing the same problem. I created a batch file which
> it runs fine using the task scheduler but only opens
> Tinn-R and R but it doesn't execute my script.
> My task scheduler executes everyday at 8:00 am
> This is my batch file:
> @echo off
> Start "" "C:\Program Files\R\R-2.7.0\bin\Rgui.exe"
> start "" "C:\Documents and
> settings\Desktop\Software\MyScript.r"
>
> What am I missing?
Rscript[.exe]
You don't want (I presume) to run a GUI to execute a script.
> --- Edward Wijaya <ewijaya at gmail.com> wrote:
>
>> You might try cron job under Windows.
>>
>> http://drupal.org/node/31506
>>
>> HTH.
>>
>> - Edward
>>
>> On Thu, May 22, 2008 at 8:51 AM, Thomas Pujol
>> <thomas.pujol at yahoo.com> wrote:
>>> I am using R in a Windows environment.
>>>
>>> I store my data in a Microsoft SQL database that
>> gets updated automatically nightly. Once my SQL db
>> is updated, I wish to automatically run an R
>> "script"
>>>
>>> Any tips on "good" ways to approach this task?
>>>
>>> Is there an easy way to "launch" an R script using
>> the Windows or other "scheduler"? Can I have an
>> R-script run every hour, and within the script check
>> to determine if my database is updated, and proceed
>> only if it is updated?
>>>
>>>
>>> [[alternative HTML version deleted]]
>>>
>>> ______________________________________________
>>> R-help at r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>> PLEASE do read the posting guide
>> http://www.R-project.org/posting-guide.html
>>> and provide commented, minimal, self-contained,
>> reproducible code.
>>>
>>
>> ______________________________________________
>> R-help at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained,
>> reproducible code.
>>
>
>
> Felipe D. Carrillo
> Fishery Biologist
> Department of the Interior
> US Fish & Wildlife Service
> California, USA
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-help
mailing list