check4valid: checks the returned value of valid8 functions

Description Usage Arguments Value Examples

View source: R/f0.rbsb1.code.r

Description

When x is character, then it is printed as well as message and according to fatal the program can be stopped.

Usage

1

Arguments

x

object to be checked.

message

Some additional message to be issued before stopping.

fatal

what to do when discovering a character? TRUE: this function prints the message and stops; FALSE: this function returns the message as a character.

Value

When the check is validated returns TRUE. If not, according to fatal prints the message and stops or returns the message.

Examples

1
2
3
4
 rbsb3k("RESET"); # needed only for R checking, to be forgotten
 check4valid("That's not good enough", fatal=FALSE);
 check4valid(TRUE);
 check4valid("A", "B C and so on.", fatal=FALSE);

rbsb documentation built on May 31, 2017, 1:45 a.m.