xerror.summary() xerror.clear(doprint=F) xerror.maxpr(times=10) xerror.setfile(files="stderr")
xerror.summary: prints out the current state of the internal error message summary table, listing the initia segment of the message, the error number, the severity level and the repetition count for each message processed.
xerror.clear: clears the internal error message table. If doprint is T the table is printed before it is cleared.
xerror.maxpr: limits to times the number of times any specific message will be queued or printed. The initial (default) value for times is 10. The internal table is still updated after times occurances of a message, but no ouput is generated.
xerror.setfile: sets the (list of) files to which the xerror messages will be sent.
Output of any specific error message is controlled by the interaction options()$warn and the severity level of the particular message, as shown in the following table: warn type level 0 1 2 value fatal 2 stop stop stop recover 1 not printed* printed stop warning 0 not printed* printed printed single -1 not printed** printed printed warn only once only once
* -- message passed to S-PLUS warning queue ** -- message passed once to S-PLUS warning queue When messages are passed to the S-PLUS warning queue, they may be printed at the termination of the outer-most S-PLUS function. Note that recover level messages are promoted to fatal when warn is 2 or -2. Also all output is supressed if warn is negative. In addition, no single message will be printed (or passed to the warning queue) more than maxpr times.
Refer to the documentation for XERROR, XERRWV and the SLATEC xerror package for further details.
Netlib reference.
#normal use of xerror.clear and xerror.summary to #control a subroutine package that uses xerror control function(arg1,.....) { #process args ... xerror.clear() #initialize the error tables #invoke the routines using xerror or xerrwv .Fortran("routinename",...) ... #if errors have been hidden, print summary if(options()$warn==0) xerror.summary() ... }