[R] commandArgs() prints warnings to STDOUT - correction

2003-02-05 Thread Vadim Ogranovich
I realized that it is not commandArgs() rather R itslef that prints the warning to the stdout (which is still not desirable of course): $ R --no-save --no-restore --silent A < /dev/null 2> /dev/null ARGUMENT 'A' __ignored__ ===original message below Dear R-Users, I was glad to hea

[R] commandArgs() prints warnings to STDOUT

2003-02-05 Thread Vadim Ogranovich
Dear R-Users, I was glad to hear that there is an ongoing work to make R more easily runnable as a batch. I'd like to raise two issues in this regards: 1. commandArgs() prints warnings to STDOUT rather than to STDERR, see example below $ cat foo.R argv <- commandArgs() $ R --no-save --no-restor

[R] find max of implicit function OR inversion of 2D mappings.

2003-01-31 Thread Vadim Ogranovich
Dear R-Users, I am looking for a help to deal with the following computational problem: I have a mapping f(x, y) -> (u, v) of [0,1]*[0,1] -> R^2. The mapping is given by tabulating f(x,y) on a uniform 2D grid and is assumed to be "interpolatable" in between the grid points (the number of points o

[R] controlling number of iterations in avas

2003-01-16 Thread Vadim Ogranovich
Dear R-Users, Is there a way to directly set a limit to the number of iterations in avas()? I am aware of delrsq argument, but I've found it difficult to use since its effect on computation time is hard to predict. For example with the default delrsq=0.01 a single iteration took ~2min to complete.

[R] interaction of options(error=) and try()

2003-01-07 Thread Vadim Ogranovich
Dear R-Users, I am somewhat confused by the interplay between options(error=) and try(). I set my error handler to an expression that dumps the frames and quits. Yet, I thought that this handler would NOT be invoked if an error happens within try(). Apparently it was. Here is the code that I ran a

[R] how to save envir. when batch is halted

2003-01-06 Thread Vadim Ogranovich
Dear R-users, If for whatever reason a batch execution of my script halts I want R to save my current environment, along with .Traceback var, in the .RData file (in other words I need something like core dump). It seems however that if execution is halted via stop() no .RData file is dumped. So m

[R] disabling NA token as na.string in read.table

2002-12-19 Thread Vadim Ogranovich
Dear R-Users, I have a csv file that has NA tokens and these tokens are perfectly good values that need not to be converted to NA by read.table(). I tried to prevent the conversion by specifying the na.strings arg., but this seems to only add to the list of NA strings, not substitute. > system("c

<    1   2