Check out the getopt package.
On Fri, Apr 17, 2009 at 11:39 AM, Juergen Rose wrote:
> Hi,
> I would like to call a R script sometimes with:
> R --slave --vanilla --args Debug=1 N=25 < test.R
> and sometimes with
> R --slave --vanilla Debug=1 < test.R
> or similar.
>
> Inside the R script I get
Hi,
I would like to call a R script sometimes with:
R --slave --vanilla --args Debug=1 N=25 < test.R
and sometimes with
R --slave --vanilla Debug=1 < test.R
or similar.
Inside the R script I get the arguments with:
args=(commandArgs(TRUE))
if(length(args)==0){
print("===No arguments s
2 matches
Mail list logo